JP2000267951A - Data transfer control system and its method - Google Patents
Data transfer control system and its methodInfo
- Publication number
- JP2000267951A JP2000267951A JP11069992A JP6999299A JP2000267951A JP 2000267951 A JP2000267951 A JP 2000267951A JP 11069992 A JP11069992 A JP 11069992A JP 6999299 A JP6999299 A JP 6999299A JP 2000267951 A JP2000267951 A JP 2000267951A
- Authority
- JP
- Japan
- Prior art keywords
- data transfer
- command
- stored
- identification information
- disconnection
- 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.)
- Pending
Links
- 238000012546 transfer Methods 0.000 title claims abstract description 84
- 238000000034 method Methods 0.000 title claims description 57
- 238000012545 processing Methods 0.000 claims abstract description 98
- 238000003780 insertion Methods 0.000 claims description 3
- 230000037431 insertion Effects 0.000 claims description 3
- 230000004044 response Effects 0.000 claims description 3
- 230000003213 activating effect Effects 0.000 claims description 2
- 239000003795 chemical substances by application Substances 0.000 description 8
- 238000010586 diagram Methods 0.000 description 8
- 238000000926 separation method Methods 0.000 description 7
- 238000004891 communication Methods 0.000 description 6
- 230000000694 effects Effects 0.000 description 5
- 238000000605 extraction Methods 0.000 description 2
- 230000002093 peripheral effect Effects 0.000 description 2
- 238000012937 correction Methods 0.000 description 1
- 238000005259 measurement Methods 0.000 description 1
- 238000002360 preparation method Methods 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
Abstract
Description
【0001】[0001]
【発明の属する技術分野】本発明は、データ転送制御、
特に、活線挿抜可能なデータ転送制御に関する。The present invention relates to a data transfer control,
In particular, the present invention relates to hot-swappable data transfer control.
【0002】[0002]
【従来の技術】この従来技術の一例が、特開平8−54
970号公報に「活線挿抜機構」として記載されてい
る。2. Description of the Related Art An example of this prior art is disclosed in Japanese Patent Application Laid-Open No. 8-54.
No. 970 describes this as a "hot wire insertion / extraction mechanism".
【0003】この従来技術の構成は、図8に示すよう
に、3つのエージェント1−1,1−2および1−3が
データ転送バス100に接続されてデータ転送を行う。
エージェント1−1〜1−3それぞれの接離予告回路2
−1〜2−3は、各エージェント1−1〜1−3のデー
タ転送バス100に対する接離動作時に接離予告信号を
他のエージェントに出力する。接離予告信号は、接離ラ
ッチ回路3−1〜3−3,4−1〜4−3によってラッ
チされる。ラッチリセット回路5−1〜5−3それぞれ
は、自エージェントによるデータ転送終了時にセットさ
れている接離ラッチ回路3−1〜3−3,4−1〜4−
3のリセットを行う。そして、再転送回路6−1〜6−
3は、データ転送終了時に接離ラッチ回路3−1〜3−
3,4−1〜4−3がセットされていれば、ローカルメ
モリに格納され、かつ直前まで転送されていたデータと
そのデータ長と転送先のアドレスとを基にそのデータの
再転送を行う。In the configuration of this prior art, as shown in FIG. 8, three agents 1-1, 1-2 and 1-3 are connected to a data transfer bus 100 to perform data transfer.
Contact / separation notice circuit 2 for each of agents 1-1 to 1-3
-1 to 2-3 output a contact / separation notice signal to another agent when each of the agents 1-1 to 1-3 is connected to / separated from the data transfer bus 100. The contact / separation notice signal is latched by the contact / separation latch circuits 3-1 to 3-3 and 4-1 to 4-3. Latch reset circuits 5-1 to 5-3 are respectively connected / separated latch circuits 3-1 to 3-3 and 4-1 to 4-4 which are set at the end of data transfer by the own agent.
3 is reset. Then, the retransfer circuits 6-1 to 6-
3 is an on / off latch circuit 3-1 to 3-
If 3, 4-1 to 4-3 are set, the data stored in the local memory and retransmitted based on the data which has been transmitted until immediately before, its data length, and the address of the transfer destination are performed. .
【0004】上記のように構成された活線挿抜機構は、
データ転送バスとの接離を予告する他のエージェントの
予告手段からの信号を保持しておき、他のエージェント
との間のデータ転送終了時に予告手段からの信号が保持
されていれば、直前に実行されていたデータ転送を再度
実行することによって、データの信頼性を確実に保証す
ることができるという効果を有する。The hot-line insertion / extraction mechanism configured as described above
The signal from the notice means of the other agent that gives notice of the connection / separation with the data transfer bus is held, and if the signal from the notice means is held when the data transfer with the other agent is completed, By executing the executed data transfer again, there is an effect that the reliability of the data can be reliably guaranteed.
【0005】[0005]
【発明が解決しようとする課題】しかしながら、上述し
た従来技術では、ソフトウェアがデータ転送にタイムア
ウト判定を設けているとエラー回避ができないという第
1の問題点がある。タイムアウト判定は、データ処理に
おいて主導権を有するソフトウェアにおけるエラー判定
の一つであって、一定時間内にデータ転送が終了しない
場合にはタイムアウトエラーとするものである。However, in the above-mentioned prior art, there is a first problem that it is not possible to avoid an error if software has provided a time-out judgment for data transfer. The timeout determination is one of error determinations in software having the initiative in data processing, and if data transfer is not completed within a predetermined time, a timeout error is determined.
【0006】これは、回路レベルでの信号転送保証を行
ったとしても、ソフトウェア側でタイムアウトエラーと
判断してしまえば、正常に転送されたかどうか、ハード
ウェアとソフトウェアとで整合がとれなくなってしまう
からである。その結果、同一データの再送が行われる可
能性が生じる。[0006] Even if signal transfer is guaranteed at the circuit level, if the software determines that a time-out error has occurred, it will not be possible to match between the hardware and software as to whether the transfer has been performed normally. Because. As a result, there is a possibility that the same data is retransmitted.
【0007】また、第2の問題点は、各エージェントが
データ保証のための専用回路(図8に示した接離予告回
路,接離ラッチ回路,ラッチリセット回路および再転送
回路)を用意しなければならないことである。The second problem is that each agent must prepare a dedicated circuit for data assurance (the contact / separation notice circuit, the contact / separation latch circuit, the latch reset circuit, and the retransfer circuit shown in FIG. 8). It must be.
【0008】本発明の目的は、データ転送中にもデータ
を保証しつつ、システムの接続形態を変更可能なデータ
転送制御システムおよびデータ転送制御方法を提供する
ことにある。It is an object of the present invention to provide a data transfer control system and a data transfer control method capable of changing the connection mode of a system while guaranteeing data even during data transfer.
【0009】また、本発明の他の目的は、データ転送対
象となるデバイスにデータ転送専用の回路を設ける必要
のないデータ転送制御システムおよびデータ転送制御方
法を提供することにある。It is another object of the present invention to provide a data transfer control system and a data transfer control method which do not require a circuit dedicated to data transfer in a device to which data is transferred.
【0010】[0010]
【課題を解決するための手段】本発明の第1のデータ転
送制御システムは、活線挿抜可能なデバイスをデータ転
送の対象とするデータ転送制御システムにおいて、前記
デバイスの挿抜に伴なうシステムの接続形態の変更時に
も、ホストコンピュータと前記デバイスとの間で転送さ
れるデータの信頼性を保証することを特徴とする。A first data transfer control system according to the present invention is a data transfer control system in which a hot-swappable device is subjected to data transfer. It is characterized in that the reliability of data transferred between the host computer and the device is guaranteed even when the connection mode is changed.
【0011】本発明の第2のデータ転送制御システム
は、活線挿抜可能なデバイスをデータ転送の対象とする
データ転送制御システムにおいて、前記デバイスが当該
システムから切断されていても、該デバイスの識別情報
がシステムに保存されている限り、アプリケーションか
らのデータ転送要求に対して、前記デバイスの切断状態
を見せず、タイムアウトエラーを意識させないように
し、一定時間以内に前記デバイスが再接続されると、前
記保存されたデバイスの識別情報を用いて、中断された
データ転送を継続することを特徴とする。According to a second data transfer control system of the present invention, in a data transfer control system in which a hot-swappable device is a target of data transfer, even if the device is disconnected from the system, the device can be identified. As long as the information is stored in the system, in response to a data transfer request from an application, the disconnection state of the device is not shown, so that a timeout error is not noticed, and when the device is reconnected within a predetermined time, The interrupted data transfer is continued using the stored device identification information.
【0012】本発明の第3のデータ転送制御システム
は、活線挿抜可能なデバイスをデータ転送の対象とする
データ転送制御システムにおいて、前記デバイスの識別
情報,前記デバイスに発行しようとするコマンドおよび
前記デバイスの接続状態を記憶する記憶手段と、前記デ
バイスが接続されると、当該デバイスの識別情報をデバ
イスから取得して前記記憶されている識別情報と比較
し、不一致なら新規接続であるため前記記憶されたコマ
ンドを消去し、また一致なら再接続であるため切断タイ
マを停止するとともにコマンドの再送指示を行うデバイ
ス接続処理手段と、アプリケーションからの前記デバイ
スに対するデータ転送要求か、または前記再送指示によ
り起動され、前記記憶手段の記憶内容によって、当該デ
バイスが接続されていれば当該コマンドを実行して前記
記憶されたコマンドを消去し、また接続されていないが
識別情報が記憶されていれば「実行中」のステータスを
前記アプリケーションに返却するコマンド実行処理手段
と、デバイスが切断されると前記接続状態を未接続と
し、切断タイマ処理手段を起動するデバイス切断処理手
段と、タイムアウトする時間を設定してタイムアウトを
待ち、この間に前記デバイス接続処理手段が実行される
と前記記憶されたコマンドを廃棄し、また前記タイムア
ウトが発生すると前記記憶されたデバイスの識別情報を
消去する切断タイマ処理手段とを備えたことを特徴とす
る。According to a third data transfer control system of the present invention, in a data transfer control system in which a hot-swappable device is subjected to data transfer, identification information of the device, a command to be issued to the device, and A storage unit for storing a connection state of the device, and when the device is connected, the identification information of the device is obtained from the device and compared with the stored identification information. Device connection processing means for erasing the transmitted command and stopping the disconnection timer because it is a reconnection if they match, and instructing the device to resend the command, or activated by a data transfer request from the application to the device or the resending instruction The device is connected according to the contents stored in the storage means. Command execution processing means for executing the command to delete the stored command, and returning a status of "executing" to the application if the connection information is not connected but identification information is stored; and When disconnected, the connection state is set to unconnected, a device disconnection processing unit that activates a disconnection timer processing unit, a time-out period is set, and a timeout is awaited. Disconnection timer processing means for discarding the set command and erasing the stored device identification information when the timeout occurs.
【0013】さらに、本発明のデータ転送制御システム
の好ましい実施の形態は、前記デバイスを切断してから
再接続するまでの時間を外部から設定可能にしたことを
特徴とする。Further, a preferred embodiment of the data transfer control system according to the present invention is characterized in that the time from disconnecting the device to reconnecting the device can be externally set.
【0014】また、本発明のデータ転送制御方法は、活
線挿抜可能なデバイスをデータ転送の対象とするデータ
転送制御方法において、前記デバイスの識別情報,前記
デバイスに発行しようとするコマンドおよび前記デバイ
スの接続状態を記憶する記憶手順と、前記デバイスが接
続されると、当該デバイスの識別情報をデバイスから取
得して前記記憶されている識別情報と比較し、不一致な
ら新規接続であるため前記記憶されたコマンドを消去
し、また一致なら再接続であるため切断タイマを停止す
るとともにコマンドの再送指示を行うデバイス接続処理
手順と、アプリケーションからの前記デバイスに対する
データ転送要求か、または前記再送指示により起動さ
れ、前記記憶された内容によって、当該デバイスが接続
されていれば当該コマンドを実行して前記記憶されたコ
マンドを消去し、また接続されていないが識別情報が記
憶されていれば「実行中」のステータスを前記アプリケ
ーションに返却するコマンド実行処理手順と、デバイス
が切断されると前記接続状態を未接続とし、切断タイマ
処理理手順を起動するデバイス切断処理手順と、タイム
アウトする時間を設定してタイムアウトを待ち、この間
に前記デバイス接続処理手順が実行されると前記記憶さ
れたコマンドを廃棄し、また前記タイムアウトが発生す
ると前記記憶されたデバイスの識別情報を消去する切断
タイマ処理手順とを有することを特徴とする。According to the data transfer control method of the present invention, in the data transfer control method in which a hot-swappable device is subjected to data transfer, identification information of the device, a command to be issued to the device, and the device And a storage procedure for storing the connection state of the device, and when the device is connected, obtains the identification information of the device from the device and compares it with the stored identification information. Device connection processing procedure for stopping the disconnection timer and instructing a command resend, and resuming the connection if the match is made, or a data transfer request from the application to the device, or activated by the resend instruction. If the device is connected according to the stored contents, A command execution processing procedure for executing the command to erase the stored command, and returning a status of “executing” to the application if the connection information is not connected but the identification information is stored, and the device is disconnected. Then, the connection state is set to unconnected, a device disconnection processing procedure for activating a disconnection timer processing procedure, a time-out period is set, and a timeout is awaited. And a disconnection timer processing procedure for deleting the stored command and deleting the stored device identification information when the timeout occurs.
【0015】より具体的には、本発明のデータ転送制御
システムは、接続したデバイス(図1の2)に発行しよ
うとするコマンドパケットの記憶手段としてのコマンド
キュー(図1の51)と、コマンドパケットの実行手段
としてのコマンド実行手段(図1−41)と、デバイス
接続の認識手段としてのデバイス接続処理手段(図1の
43)と、デバイス接続状態の記憶手段としてのデバイ
ス接続フラグ(図1の53)と、デバイス切断の認識手
段としてのデバイス切断処理手段(図1の44)と、デ
バイスの識別情報を記憶する手段としてのIDバッファ
(図1の52)と、デバイス切断後の時間を計測する手
段としての切断タイマ処理手段(図1の42)から構成
されており、一定時間以内にデバイスが切断、再接続さ
れた場合に、記憶した識別情報を用い、切断されたデバ
イスを認識することによって、中断されたデータ転送を
継続するよう動作する。More specifically, the data transfer control system according to the present invention comprises a command queue (51 in FIG. 1) as storage means for a command packet to be issued to a connected device (2 in FIG. 1); A command execution unit (FIG. 1-41) as a packet execution unit, a device connection processing unit (43 in FIG. 1) as a device connection recognition unit, and a device connection flag (FIG. 1) as a device connection state storage unit. 53), device disconnection processing means (44 in FIG. 1) as recognition means for device disconnection, ID buffer (52 in FIG. 1) as means for storing device identification information, and time after device disconnection. It consists of a disconnection timer processing means (42 in FIG. 1) as a means for measuring, and stores when a device is disconnected and reconnected within a predetermined time. Using the identification information, by recognizing the cut device operates to continue the interrupted data transfer.
【0016】さらに、本発明のデータ転送制御システム
は、上述のデータ転送制御システムにデバイスの再接続
を認識する時間の記憶手段としてのタイマ値レジスタ
(図6の54)と、時間を設定可能な入力手段としての
入力装置(図6の6)とを備え、再接続を認識する時間
をユーザーが設定できるようにした。Further, in the data transfer control system of the present invention, a timer value register (54 in FIG. 6) as storage means for recognizing reconnection of a device to the above-mentioned data transfer control system, and a time can be set. An input device (6 in FIG. 6) is provided as input means so that the user can set the time for recognizing reconnection.
【0017】[0017]
【発明の実施の形態】次に、本発明の実施の形態につい
て図面を参照して詳細に説明する。Next, embodiments of the present invention will be described in detail with reference to the drawings.
【0018】図1を参照すると、本発明の第1の実施の
形態は、ホストコンピュータ1内に、デバイス制御装置
4と記憶装置5を備えている。ホストコンピュータ1
は、データ転送を行う相手のデバイス2に接続されてお
り、アプリケーション3はデバイス2を操作するため
に、デバイス制御装置4を利用する。デバイス2は、活
線挿抜可能なインタフェースを備えたホストコンピュー
タ1の周辺機器であり、ホストコンピュータ1に複数台
の接続が可能となっている。Referring to FIG. 1, in the first embodiment of the present invention, a host computer 1 includes a device control device 4 and a storage device 5. Host computer 1
Is connected to the device 2 of the data transfer destination, and the application 3 uses the device control device 4 to operate the device 2. The device 2 is a peripheral device of the host computer 1 having an interface capable of hot-swapping, and a plurality of devices can be connected to the host computer 1.
【0019】デバイス制御装置4は、コマンド実行処理
手段41と、切断タイマ処理手段42と、デバイス接続
処理手段43と、デバイス切断処理手段44を備えてい
る。また、記憶装置5は、コマンドキュー51と、ID
バッファ52と、デバイス接続フラグ53を備える。The device control device 4 includes command execution processing means 41, disconnection timer processing means 42, device connection processing means 43, and device disconnection processing means 44. The storage device 5 includes a command queue 51 and an ID
A buffer 52 and a device connection flag 53 are provided.
【0020】これらの各手段はそれぞれ、概略つぎのよ
うに動作する。コマンドキュー51は、デバイス2に発
行しようとするコマンドの記憶手段であり、転送しよう
とするデバイスのアドレス、データ転送方向、データサ
イズ、データのアドレスから構成されたコマンドを複数
格納している。Each of these means operates roughly as follows. The command queue 51 is a storage unit of a command to be issued to the device 2, and stores a plurality of commands including an address of a device to be transferred, a data transfer direction, a data size, and a data address.
【0021】コマンド実行処理手段41は、コマンドキ
ュー51から、コマンドを読み出して実行する。実行の
結果は成功、失敗、実行中といったステータスで示さ
れ、アプリケーション3に返却される。The command execution processing means 41 reads a command from the command queue 51 and executes the command. The execution result is indicated by a status such as success, failure, or being executed, and is returned to the application 3.
【0022】デバイス接続処理手段43は、接続された
デバイス2の構成を読み出す。また、デバイス2のシリ
アル番号を読み出し、デバイスの識別情報を記憶する手
段であるIDバッファ52の内容と比較を行うことによ
り、デバイス接続後に初期化を行うのかどうかを判断す
る。本実施の形態では、IDバッファ52にデバイスの
シリアル番号を格納するものとする。The device connection processing means 43 reads the configuration of the connected device 2. Further, by reading out the serial number of the device 2 and comparing it with the contents of the ID buffer 52 which is a means for storing the identification information of the device, it is determined whether or not to initialize after connecting the device. In the present embodiment, the serial number of the device is stored in the ID buffer 52.
【0023】デバイス切断処理手段44は、切断タイマ
処理手段42を起動し、デバイス切断が発生してからの
時間計測を行う。The device disconnection processing means 44 activates the disconnection timer processing means 42 and measures time after the occurrence of device disconnection.
【0024】切断タイマ処理手段42は、一定時間が経
過すると、デバイス2の再接続が行われなかったものと
して、IDバッファ52の内容を消去する。After a lapse of a predetermined time, the disconnection timer processing means 42 determines that the reconnection of the device 2 has not been performed, and erases the contents of the ID buffer 52.
【0025】次に、図1および、図2から図5のフロー
チャートを参照して本実施の形態の動作について説明す
る。Next, the operation of the present embodiment will be described with reference to FIG. 1 and the flowcharts of FIGS.
【0026】ホストコンピュータ1は、デバイス2がホ
ストコンピュータ1と切断、または接続されると、割込
みを発生することにより、デバイス制御装置4を起動す
ることができる。起動されたデバイス制御装置4は、デ
バイスの接続状態に応じ、実行する内部処理を決定す
る。When the device 2 is disconnected or connected to the host computer 1, the host computer 1 can activate the device control device 4 by generating an interrupt. The activated device control device 4 determines an internal process to be executed according to the connection state of the device.
【0027】(1)デバイス接続処理 図1の構成図と図2のフローチャートを用いて、デバイ
ス接続処理を説明する。(1) Device Connection Process The device connection process will be described with reference to the configuration diagram of FIG. 1 and the flowchart of FIG.
【0028】デバイス2がホストコンピュータ1に接続
されると、ホストコンピュータ1は割込みを発生し、デ
バイス接続処理手段43を呼び出す。デバイス接続処理
手段43は、デバイス2の持っている構成情報を取得す
る(ステップA1)。構成情報とは、たとえばUSBの
ようなデバイスであれば、データ通信の論理チャネルが
それぞれデータの入力用かあるいは出力用であるか、ま
たデータパケットのサイズといった情報で構成されてい
る。When the device 2 is connected to the host computer 1, the host computer 1 generates an interrupt and calls the device connection processing means 43. The device connection processing unit 43 acquires the configuration information possessed by the device 2 (Step A1). The configuration information is, for example, a device such as a USB, and is configured with information such as whether a logical channel for data communication is for data input or data output, and the size of a data packet.
【0029】次に、この構成情報を基にデータ通信の論
理チャネルの初期化を行う(ステップA2)。初期化に
あたっては、エラー訂正のためのパケット番号を初期値
に設定するなど、通信対象のデバイスとのデータ同期が
とれるよう状態設定を行う。Next, a logical channel for data communication is initialized based on the configuration information (step A2). At the time of initialization, state setting is performed such that the packet number for error correction is set to an initial value so that data synchronization with the communication target device can be achieved.
【0030】次に、接続されたデバイスのシリアル番号
をデバイス2から取得する(ステップA3)。シリアル
番号は、通常、重複しないため、個別のデバイスの識別
に使用するのに都合が良いからである。Next, the serial number of the connected device is obtained from the device 2 (step A3). This is because serial numbers are usually not duplicated and are therefore convenient for use in identifying individual devices.
【0031】次に、読み出したデバイス2のシリアル番
号とIDバッファ52の内容を比較する(ステップA
4)。この比較の結果、デバイス2のシリアル番号とI
Dバッファ52の内容とが一致したならば、デバイス2
は再接続されたと判断する。そして、後述のように、切
断タイマ処理手段42によって起動したタイマを停止
し、切断タイマによる時間測定を停止する(ステップA
5)。Next, the read serial number of the device 2 is compared with the contents of the ID buffer 52 (step A).
4). As a result of this comparison, the serial number of device 2 and I
If the contents of the D buffer 52 match, the device 2
Determines that it has been reconnected. Then, as described later, the timer started by the disconnection timer processing unit 42 is stopped, and the time measurement by the disconnection timer is stopped (step A).
5).
【0032】次に、中断されていたコマンドをデバイス
2に再送するよう指示する(ステップA6)。この指示
によって、コマンド実行処理手段41が起動される。Next, an instruction is issued to retransmit the interrupted command to the device 2 (step A6). With this instruction, the command execution processing unit 41 is started.
【0033】一方、ステップA4において、デバイス2
のシリアル番号とIDバッファ52の内容が一致しない
ならば、新しくデバイスが接続されたと判断する。この
場合、コマンドキュー51の内容を消去し、以後受け付
けるコマンドはデバイスの接続した後のものとする(ス
テップA7)。On the other hand, in step A4, the device 2
If the serial number does not match the contents of the ID buffer 52, it is determined that a new device has been connected. In this case, the contents of the command queue 51 are deleted, and the commands received thereafter are those after the connection of the device (step A7).
【0034】次に、デバイス接続フラグ53を設定し、
現在、デバイスが接続されていることが、デバイス制御
装置4でわかるようにする(ステップA8)。Next, the device connection flag 53 is set,
The fact that the device is currently connected is made known by the device control device 4 (step A8).
【0035】次に、デバイスのシリアル番号をIDバッ
ファ52に保存しておき、次回のデバイス接続時に照会
できるようにする(ステップA9)。Next, the serial number of the device is stored in the ID buffer 52 so that it can be referred to at the time of the next device connection (step A9).
【0036】(2)コマンド実行処理 次に、図1の構成図と図3のフローチャートを用いて、
コマンド実行処理を説明する。(2) Command execution processing Next, using the configuration diagram of FIG. 1 and the flowchart of FIG.
The command execution processing will be described.
【0037】アプリケーション3から、デバイス2に対
してデータ転送を要求すると、コマンド実行処理が実行
される。このとき、アプリケーション3の要求はコマン
ドキュー51に保存される。When the application 3 requests data transfer to the device 2, a command execution process is executed. At this time, the request from the application 3 is stored in the command queue 51.
【0038】コマンド実行処理手段41はコマンドキュ
ー51からコマンドのパケットを読み出す(ステップB
1)。The command execution processing means 41 reads a command packet from the command queue 51 (step B).
1).
【0039】次に、コマンド実行処理41はデバイス接
続フラグ53から、現在のデバイス2の接続状態を判断
する(ステップB2)。その結果、デバイス2が接続さ
れていないならば、再接続の可能性があるかどうかを判
定するため、IDバッファ52にシリアル番号が保存さ
れているかどうかを調べる(ステップB3)。もしも、
保存されているならば、切断のタイムアウトになってい
ないため、コマンドのステータスを「実行中」として、
終了する(ステップB4)。Next, the command execution process 41 determines the current connection state of the device 2 from the device connection flag 53 (step B2). As a result, if the device 2 is not connected, it is checked whether a serial number is stored in the ID buffer 52 to determine whether there is a possibility of reconnection (step B3). If,
If it is, the disconnection has not timed out and the status of the command
The process ends (step B4).
【0040】一方、シリアル番号が保存されていない場
合は、以前に同一のデバイスが接続されていなかったの
で、コマンドの継続を行う必要がないため、コマンドの
ステータスを「失敗」にする(ステップB5)。この場
合、このコマンドは処理されたので、コマンドキューか
ら廃棄する(ステップB10)。On the other hand, if the serial number is not stored, the same device has not been connected before, and there is no need to continue the command, so that the status of the command is set to "failed" (step B5). ). In this case, since this command has been processed, it is discarded from the command queue (step B10).
【0041】ステップB2において、デバイス2が接続
状態であれば、コマンド実行処理手段41はデバイス2
に対してコマンドを実行する(ステップB6)。具体的
には、デバイス2の備えているレジスタに対してコマン
ドのデータバイトを書き込む等の手続きを行う。In step B2, if the device 2 is in the connected state, the command execution processing means 41
Is executed (step B6). Specifically, a procedure such as writing a data byte of a command to a register provided in the device 2 is performed.
【0042】次に、コマンドの実行結果をデバイス2か
ら読み出し、結果を判定する(ステップB7)。その結
果、コマンドが正しく実行されたならば、それに伴うデ
ータ転送の処理も成功したとして、「成功」のステータ
スを設定する(ステップB8)。Next, the command execution result is read from the device 2 and the result is determined (step B7). As a result, if the command is executed correctly, it is determined that the data transfer process accompanying the command is also successful, and the status of “success” is set (step B8).
【0043】一方、デバイス2から読み出したレジスタ
の内容が不正など、コマンドが正しく実行されなかった
場合には「失敗」のステータスを設定する(ステップB
9)。ステップB8またはB9によって、コマンドが実
行されたならばコマンドキュー51からコマンドを廃棄
する(ステップB10)。On the other hand, if the command is not correctly executed, for example, if the contents of the register read from the device 2 are invalid, the status of "failure" is set (step B).
9). If the command is executed in step B8 or B9, the command is discarded from the command queue 51 (step B10).
【0044】以上のコマンド実行処理によって設定され
たコマンド実行のステータスは、アプリケーション3に
通知される。The command execution status set by the above-described command execution processing is notified to the application 3.
【0045】(3)デバイス切断処理 次に、図1の構成図と図4のフローチャートを用いて、
デバイス切断処理を説明する。(3) Device disconnection processing Next, using the configuration diagram of FIG. 1 and the flowchart of FIG.
The device disconnection processing will be described.
【0046】デバイス2がホストコンピュータ1から切
断されると、ホストコンピュータ1は割込みを発生し、
デバイス切断処理手段44を呼び出す。When the device 2 is disconnected from the host computer 1, the host computer 1 generates an interrupt,
The device disconnection processing means 44 is called.
【0047】デバイス切断処理手段44は、デバイス接
続フラグ53を更新し、デバイス2が接続されていない
状態とする(ステップC1)。The device disconnection processing means 44 updates the device connection flag 53 so that the device 2 is not connected (step C1).
【0048】次に、切断タイマ処理手段42を起動する
(ステップC2)。切断タイマ処理手段42は、デバイ
ス2の切断後、再接続を許可する時間の測定を開始す
る。Next, the disconnection timer processing means 42 is started (step C2). After the disconnection of the device 2, the disconnection timer processing unit 42 starts measuring the time during which reconnection is permitted.
【0049】(4)切断タイマ処理 次に、図1の構成図と図5のフローチャートを用いて、
切断タイマ処理を説明する。(4) Disconnect Timer Processing Next, using the configuration diagram of FIG. 1 and the flowchart of FIG.
The disconnection timer process will be described.
【0050】切断タイマ処理手段42は、デバイス切断
処理手段44から起動され、図5のフローチャートの制
御を行う。The disconnection timer processing means 42 is started by the device disconnection processing means 44 and controls the flow chart of FIG.
【0051】切断タイマ処理手段42は、タイムアウト
する時間を設定し(ステップD1)、起動したタイマの
タイムアウトを待つ(ステップD2)。この間に、デバ
イス2が接続されて、デバイス接続処理手段43が実行
されたならば、前述のように、タイマの停止が行われる
ため、コマンドキュー51から、コマンドを破棄して処
理を終了する(ステップD6)。The disconnection timer processing means 42 sets a time-out period (step D1) and waits for the activated timer to time-out (step D2). During this time, if the device 2 is connected and the device connection processing means 43 is executed, the timer is stopped as described above, so that the command is discarded from the command queue 51 and the process is terminated ( Step D6).
【0052】一方、ステップD3において、タイムアウ
トが発生したならば、IDバッファ52の内容を消去し
(ステップD4)、デバイス2が再接続された場合であ
っても、コマンドの実行が継続されないようにする。こ
れは、図2のステップA4においてノーとなり、ステッ
プA6に移行せず、したがって、コマンド実行処理手段
41が起動されないからである。そして、「実行中」に
設定されたままのコマンドのステータスを「失敗」に
し、(ステップD5)、コマンドキュー51から、この
コマンドを廃棄する(ステップD6)。On the other hand, if a time-out occurs in step D3, the contents of the ID buffer 52 are deleted (step D4) so that the execution of the command is not continued even when the device 2 is reconnected. I do. This is because the answer in step A4 in FIG. 2 is NO, and the process does not proceed to step A6, so that the command execution processing unit 41 is not activated. Then, the status of the command which is still set to "executing" is set to "failure" (step D5), and the command is discarded from the command queue 51 (step D6).
【0053】(5)デバイスが切断、再接続された場合
の実施例 以下に、デバイス2が新規に接続された後、データ転送
中に切断され、次に、再接続された場合の例について、
処理全体の流れを説明する。(5) Embodiment when Device is Disconnected and Reconnected The following is an example of a case where the device 2 is newly connected, disconnected during data transfer, and then reconnected.
The flow of the entire process will be described.
【0054】デバイス2が新規に接続されると、デバイ
ス接続処理手段43が実行される。すなわち、デバイス
2の構成情報を取得し(図2のステップA1)、この構
成情報を基にデータ通信の論理チャネルの初期化を行う
(ステップA2)。次に、接続されたデバイスのシリア
ル番号をデバイス2から取得し(ステップA3)、読み
出したシリアル番号を、IDバッファ52の内容と比較
する(ステップA4)。この時点では、デバイス2は新
規に接続されたため、IDバッファ52には、シリアル
番号は格納されていない。このため、コマンドキュー5
1の内容が消去され(ステップA7)、デバイス接続フ
ラグ53を接続状態に設定し(ステップA8)、読み出
したシリアル番号をIDバッファ52に保存しておく
(ステップA9)。When the device 2 is newly connected, the device connection processing means 43 is executed. That is, the configuration information of the device 2 is obtained (Step A1 in FIG. 2), and the logical channel of the data communication is initialized based on the configuration information (Step A2). Next, the serial number of the connected device is obtained from the device 2 (step A3), and the read serial number is compared with the contents of the ID buffer 52 (step A4). At this point, since the device 2 has been newly connected, no serial number is stored in the ID buffer 52. Therefore, the command queue 5
1 is deleted (step A7), the device connection flag 53 is set to the connected state (step A8), and the read serial number is stored in the ID buffer 52 (step A9).
【0055】このようにして、図2のデバイス接続処理
を終了し、アプリケーション3から、デバイス2の操作
を行うことが可能となる。アプリケーション3から、デ
バイス2に対して要求されたコマンドは、コマンドキュ
ー51に書きこまれ、コマンド実行処理手段41が実行
される。In this way, the device connection processing of FIG. 2 is completed, and the application 3 can operate the device 2. The command requested from the application 3 to the device 2 is written in the command queue 51, and the command execution processing unit 41 is executed.
【0056】コマンド実行処理手段41は、パケットキ
ューからコマンドデータが読み出される(図3のステッ
プB1)。現在、デバイス接続フラグ53は接続状態に
設定されたままなので、コマンドを実行する(ステップ
B6)。この結果(ステップB7)によって、ステータ
スに成功,失敗が設定されることになる(ステップB
8,B9)。次に、コマンドは実行されたために、コマ
ンドキュー51から廃棄される(ステップB10)。The command execution processing means 41 reads command data from the packet queue (Step B1 in FIG. 3). Since the device connection flag 53 is still set to the connection state, the command is executed (step B6). As a result (step B7), the status is set to success or failure (step B7).
8, B9). Next, since the command has been executed, it is discarded from the command queue 51 (step B10).
【0057】このタイミングでデバイス2がホストコン
ピュータ1から切断されると、デバイス切断処理手段4
4が呼び出される。デバイス切断処理は、デバイス接続
フラグ53を未接続状態に更新し(図4のステップC
1)、切断タイマ処理手段42を起動する(ステップC
2)。When the device 2 is disconnected from the host computer 1 at this timing, the device disconnection processing means 4
4 is called. The device disconnection process updates the device connection flag 53 to an unconnected state (step C in FIG. 4).
1), start the disconnection timer processing means 42 (step C)
2).
【0058】切断タイマ処理では、タイムアウト時間の
設定を行い、タイムアウトを待つ(図5のステップD
1,D2)。このタイムアウト待ち状態の間、デバイス
2へのコマンドはコマンドキュー51に書き込まれても
廃棄されず、「実行中」のステータスを返却することに
なる(図3のステップB4)。従って、アプリケーショ
ン3からはデータ転送の完了を待っている状態として扱
われる。In the disconnection timer process, a timeout period is set, and a timeout is waited for (step D in FIG. 5).
1, D2). During the timeout waiting state, the command to the device 2 is not discarded even if written into the command queue 51, and the status of "executing" is returned (step B4 in FIG. 3). Therefore, the application 3 is treated as a state waiting for the completion of data transfer.
【0059】この例では、待っている間にデバイス2が
接続され、再びデバイス接続処理手段43が実行され
る。デバイス接続処理手段43は、構成情報を取得し、
構成情報を基にデータ通信の論理チャネルの初期化を行
う(図2のステップA1,A2)。次に、接続されたデ
バイスのシリアル番号をデバイス2から取得し(ステッ
プA3)、読み出したシリアル番号を、IDバッファ5
2の内容と比較する(ステップA4)。IDバッファ5
2には、デバイス2のシリアル番号が格納されているた
め、切断タイマ処理手段42によって起動したタイマを
停止し(ステップA5)、切断されたデバイス2の再接
続が行われたと判断する。In this example, the device 2 is connected while waiting, and the device connection processing means 43 is executed again. The device connection processing unit 43 acquires the configuration information,
A logical channel for data communication is initialized based on the configuration information (steps A1 and A2 in FIG. 2). Next, the serial number of the connected device is obtained from the device 2 (step A3), and the read serial number is stored in the ID buffer 5.
2 (step A4). ID buffer 5
Since the serial number of the device 2 is stored in 2, the timer started by the disconnection timer processing unit 42 is stopped (step A5), and it is determined that the disconnected device 2 has been reconnected.
【0060】次に、中断されていたコマンドをデバイス
2に再送するよう指示する(ステップA6)。この指示
によって、コマンド実行処理手段41が再度起動し、今
度はコマンドの実行が行われる。この時には、ステータ
スも「成功」か「失敗」となり、(図3のステップB
8,B9)コマンドキュー51からコマンドの廃棄が行
われることになる(ステップB10)。Next, an instruction is given to retransmit the interrupted command to the device 2 (step A6). In response to this instruction, the command execution processing means 41 is activated again, and the command is executed this time. At this time, the status is also “success” or “failure” (step B in FIG. 3).
8, B9) Commands are discarded from the command queue 51 (step B10).
【0061】以上により、データ転送が完了したことに
なり、アプリケーション3からは、データ転送の完了待
ち状態から解放される。As described above, the data transfer is completed, and the application 3 is released from the data transfer completion waiting state.
【0062】(6)デバイスが切断、タイムアウト後に
再接続された場合の実施例 以下に、デバイス2がデータ転送中に切断され、次に再
接続された場合の例について、処理全体の流れを説明す
る。(6) Embodiment when Device is Disconnected and Reconnected After Timeout The following is an explanation of the flow of the entire processing in an example where the device 2 is disconnected during data transfer and then reconnected. I do.
【0063】タイムアウトを待つまでの手順は、(5)
で説明した処理と同じになる。タイムアウトが発生した
ならば、図5のステップD4において、IDバッファ5
2の内容を消去し、デバイス2が再接続された場合であ
っても、コマンドの実行が継続されないようにする(図
2のステップA4においてノー)。The procedure for waiting for a timeout is as follows:
The processing is the same as that described above. If a time-out has occurred, in step D4 of FIG.
2 is erased so that the execution of the command is not continued even when the device 2 is reconnected (No in step A4 in FIG. 2).
【0064】次に、「実行中」に設定されたままのコマ
ンドを「失敗」にし(図5のステップD5)、コマンド
キュー51からコマンドを廃棄する(ステップD6)。
この処理によって、「実行中」のままであったコマンド
は処理を完了する。Next, the command set as "executing" is set to "failure" (step D5 in FIG. 5), and the command is discarded from the command queue 51 (step D6).
With this process, the command that has been “executing” completes the process.
【0065】この例では、これらの処理の後にデバイス
2が再接続され、デバイス接続処理手段43が実行され
るものとする。デバイス接続処理手段43では、デバイ
ス2の構成情報を取得し、構成情報を基にデータ通信の
論理チャネルの初期化を行い(図2のステップA1,A
2)、接続されたデバイスのシリアル番号をデバイス2
から取得し(ステップA3)、読み出したシリアル番号
とIDバッファ52の内容を比較するが、IDバッファ
52にはデバイス2のシリアル番号は格納されていない
ため、コマンドキュー51の内容が消去される(ステッ
プA7)。次に、デバイス接続フラグ53をデバイス接
続状態に設定し(ステップA8)、次のデバイス切断に
備えて、読み出したデバイスのシリアル番号をIDバッ
ファ52に保存する(ステップA9)。In this example, it is assumed that after these processes, the device 2 is reconnected and the device connection processing means 43 is executed. The device connection processing means 43 acquires the configuration information of the device 2 and initializes a logical channel for data communication based on the configuration information (steps A1 and A2 in FIG. 2).
2) Enter the serial number of the connected device to Device 2.
(Step A3), and the read serial number is compared with the content of the ID buffer 52. Since the serial number of the device 2 is not stored in the ID buffer 52, the content of the command queue 51 is deleted (step A3). Step A7). Next, the device connection flag 53 is set to the device connection state (step A8), and the read serial number of the device is stored in the ID buffer 52 in preparation for the next device disconnection (step A9).
【0066】次に、本発明の第2の実施形態について図
面を参照して説明する。Next, a second embodiment of the present invention will be described with reference to the drawings.
【0067】図6を参照すると、本発明の第2の実施形
態は、ホストコンピュータ10内に、デバイス制御装置
40と記憶装置50を備えている。ホストコンピュータ
10は、データ転送を行う相手のデバイス2と、タイマ
値入力を行うための入力装置6とに接続されており、ア
プリケーション3はデバイス2を操作するために、デバ
イス制御装置4を利用する。デバイス2は、活線挿抜可
能なインタフェースを備えたホストコンピュータ1の周
辺機器であり、ホストコンピュータ1に複数台の接続が
可能となっている。Referring to FIG. 6, the second embodiment of the present invention includes a device control device 40 and a storage device 50 in a host computer 10. The host computer 10 is connected to a device 2 to which data is transferred and an input device 6 for inputting a timer value. The application 3 uses the device control device 4 to operate the device 2. . The device 2 is a peripheral device of the host computer 1 having an interface capable of hot-swapping, and a plurality of devices can be connected to the host computer 1.
【0068】デバイス制御装置4は、コマンド実行処理
手段41と、切断タイマ処理手段45と、デバイス接続
処理手段43と、デバイス切断処理手段44を備えてい
る。また、記憶装置50は、コマンドキュー51と、I
Dバッファ52と、デバイス接続フラグ53と、タイマ
値レジスタ54を備える。図6のデバイス制御装置40
を構成する各処理手段は、切断タイマ処理手段45以外
は図1に示した、同一の参照番号の処理手段と同一であ
る。The device control device 4 includes a command execution processing means 41, a disconnection timer processing means 45, a device connection processing means 43, and a device disconnection processing means 44. Further, the storage device 50 stores the command queue 51 and the I
A D buffer 52, a device connection flag 53, and a timer value register 54 are provided. The device control device 40 of FIG.
Are the same as the processing units having the same reference numbers shown in FIG. 1 except for the disconnection timer processing unit 45.
【0069】切断タイマ処理手段45については、図6
の構成図と図7のフローチャートを用いて説明する。FIG. 6 shows the disconnection timer processing means 45.
This will be described with reference to the block diagram of FIG.
【0070】切断タイマ処理手段45は、デバイス切断
処理手段44から起動されると、タイマ値レジスタ54
のタイムアウト値を読み出して(図7のステップE
1)、タイムアウトする時間を設定し(ステップE
2)、起動したタイマのタイムアウトを待つ(ステップ
A3)。この間に、デバイス2が接続されて、デバイス
接続処理手段43が実行されたならば、第1の実施の形
態におけるのと同様に、タイマの停止が行われるため、
コマンドキュー51からコマンドを破棄して処理を終了
する(ステップE7)。When the disconnection timer processing means 45 is activated by the device disconnection processing means 44, the timer value register 54
Is read out (step E in FIG. 7).
1) Set a time-out period (step E)
2) Wait for the activated timer to time out (step A3). During this time, if the device 2 is connected and the device connection processing means 43 is executed, the timer is stopped as in the first embodiment.
The command is discarded from the command queue 51, and the process ends (step E7).
【0071】一方、タイムアウトが発生したならば(ス
テップE4)、IDバッファ52の内容を消去し(ステ
ップE5)、デバイス2が再接続された場合であって
も、コマンドの実行が継続されないようにする。これ
は、図2のステップA4においてノーとなり、ステップ
A6に移行せず、したがってコマンド実行処理手段41
が起動されないからである。そして、「実行中」に設定
されたままのコマンドのステータスを「失敗」にし(ス
テップE6)、コマンドキュー51から、このコマンド
を廃棄する(ステップD7)。On the other hand, if a time-out occurs (step E4), the contents of the ID buffer 52 are deleted (step E5) so that the execution of the command is not continued even if the device 2 is reconnected. I do. This is NO at step A4 in FIG. 2 and does not proceed to step A6.
Is not started. Then, the status of the command which has been set to "executing" is set to "failed" (step E6), and the command is discarded from the command queue 51 (step D7).
【0072】入力装置6は、ユーザの時間設定入力を受
け付け、タイムアウト時間をタイマ値レジスタ54に保
持する。The input device 6 accepts the user's time setting input, and stores the timeout time in the timer value register 54.
【0073】本実施の形態の特有の効果は、デバイスを
切断してから再接続までの時間を可変にできるため、た
とえば、デバイスの接続形態を変更するために、ユーザ
がデバイスの切断と再接続を行うような、コンピュータ
処理からすると比較的長時間を要する作業を行なう場合
であっても、データ転送を継続して行えるシステムを提
供することができることである。A unique effect of this embodiment is that the time from disconnection of a device to reconnection can be made variable. For example, in order to change the connection mode of the device, the user disconnects and reconnects the device. It is possible to provide a system that can continue data transfer even when performing an operation that requires a relatively long time in terms of computer processing, such as performing a computer process.
【0074】逆に、別のユーザにとっては、デバイスの
切断と再接続を行ったにも拘わらず、デバイスにコマン
ドが継続して実行されることが不都合となる可能性があ
る。例えば、プリンタなど、一連のデータ列が続くこと
によって、描画を実行するようなデータ転送を行うデバ
イスなどでは、データ転送が継続すると誤印字の原因と
なってしまう。この場合、タイマ値54をより小さい値
に設定することで、問題を回避することができるという
効果が生じる。On the other hand, it may be inconvenient for another user that commands are continuously executed on the device despite disconnection and reconnection of the device. For example, in a device such as a printer that performs a data transfer for executing drawing by a series of data strings continuing, if the data transfer is continued, it may cause erroneous printing. In this case, setting the timer value 54 to a smaller value has the effect of avoiding the problem.
【0075】なお、以上に説明したデータ転送制御方法
をコンピュータに実行させるためのプログラムを半導体
メモリ,磁気ディスク等のコンピュータ読み込み可能な
記録媒体に記憶し、ホストコンピュータ1に読み込ませ
て実行させるようにしてもよい。このプログラムはホス
トコンピュータ1を制御して、上述の方法を実行させ
る。A program for causing a computer to execute the data transfer control method described above is stored in a computer-readable recording medium such as a semiconductor memory or a magnetic disk, and is read and executed by the host computer 1. You may. This program controls the host computer 1 to execute the above-described method.
【0076】[0076]
【発明の効果】本発明の第1の効果は、ソフトウェアが
データ転送にタイムアウト判定を設けていてもエラー回
避が可能なことである。その理由は、デバイスが切断さ
れていても、コマンド実行処理手段は、IDバッファに
そのデバイスの識別情報が保存されている限り、「実行
中」のステータスをアプリケーションに返却するので、
アプリケーションにハードウェアの切断状態を見せず、
エラーを意識させないようにできるからである。A first effect of the present invention is that an error can be avoided even if software has a timeout judgment for data transfer. The reason is that even if the device is disconnected, the command execution processing means returns the status of “executing” to the application as long as the identification information of the device is stored in the ID buffer,
Don't show applications disconnected hardware
This is because it is possible to hide the error.
【0077】この結果、たとえば、USB(Universal S
erial Bus)のようなデータバスにおいて、ハブに接続さ
れたデバイスが全て使用中にも拘わらず、さらにデバイ
スを追加接続したい場合、一部のデバイスを切断して、
増設するハブに差し替える必要があるが、このように長
時間を要する作業の場合にも、データ転送を継続して行
えるようになる。As a result, for example, a USB (Universal S
(Erial Bus), if all devices connected to the hub are in use and you want to connect more devices, disconnect some devices,
Although it is necessary to replace the hub with an additional hub, data transfer can be continued even in the case of such a work requiring a long time.
【0078】また、第2の効果は、各デバイスがデータ
保証のための専用回路を用意しなくてもよいということ
である。The second effect is that each device does not need to prepare a dedicated circuit for data assurance.
【図1】本発明の第1の実施の形態の構成を示すブロッ
ク図FIG. 1 is a block diagram showing a configuration of a first exemplary embodiment of the present invention.
【図2】本発明の第1の実施の形態における接続処理の
フローチャートFIG. 2 is a flowchart of a connection process according to the first embodiment of the present invention;
【図3】本発明の第1の実施の形態におけるコマンド実
行処理のフローチャートFIG. 3 is a flowchart of a command execution process according to the first embodiment of the present invention.
【図4】本発明の第1の実施の形態における切断処理の
フローチャートFIG. 4 is a flowchart of a disconnection process according to the first embodiment of the present invention.
【図5】本発明の第1の実施の形態における切断タイマ
処理のフローチャートFIG. 5 is a flowchart of a disconnection timer process according to the first embodiment of the present invention.
【図6】本発明の第2の実施の形態の構成を示すブロッ
ク図FIG. 6 is a block diagram showing a configuration of a second exemplary embodiment of the present invention.
【図7】本発明の第2の実施の形態における切断タイマ
処理のフローチャートFIG. 7 is a flowchart of a disconnection timer process according to the second embodiment of the present invention.
【図8】従来のデータ転送システム例の構成を示すブロ
ック図FIG. 8 is a block diagram showing a configuration of an example of a conventional data transfer system.
1 ホストコンピュータ 2 デバイス 3 アプリケーション 4 デバイス制御装置 5 記憶装置 10 ホストコンピュータ 40 デバイス制御装置 41 コマンド実行処理手段 42 切断タイマ処理手段 43 デバイス接続処理手段 44 デバイス切断処理手段 45 切断タイマ処理手段 51 コマンドキュー 52 IDバッファ 53 デバイス接続フラグ 54 タイマ値レジスタ DESCRIPTION OF SYMBOLS 1 Host computer 2 Device 3 Application 4 Device control device 5 Storage device 10 Host computer 40 Device control device 41 Command execution processing means 42 Disconnection timer processing means 43 Device connection processing means 44 Device disconnection processing means 45 Disconnection timer processing means 51 Command queue 52 ID buffer 53 Device connection flag 54 Timer value register
Claims (8)
対象とするデータ転送制御システムにおいて、前記デバ
イスの挿抜に伴なうシステムの接続形態の変更時にも、
ホストコンピュータと前記デバイスとの間で転送される
データの信頼性を保証することを特徴とするデータ転送
制御システム。In a data transfer control system in which a hot-swappable device is a target of data transfer, even when a connection state of the system is changed due to the insertion / removal of the device,
A data transfer control system for guaranteeing the reliability of data transferred between a host computer and said device.
対象とするデータ転送制御システムにおいて、 前記デバイスが当該システムから切断されていても、該
デバイスの識別情報がシステムに保存されている限り、
アプリケーションからのデータ転送要求に対して、前記
デバイスの切断状態を見せず、タイムアウトエラーを意
識させないようにし、 一定時間以内に前記デバイスが再接続されると、前記保
存されたデバイスの識別情報を用いて、中断されたデー
タ転送を継続することを特徴とするデータ転送制御シス
テム。2. A data transfer control system in which a hot-swappable device is a target of data transfer, even if the device is disconnected from the system, as long as the identification information of the device is stored in the system.
In response to a data transfer request from an application, the disconnection state of the device is not shown, and a timeout error is not considered.When the device is reconnected within a predetermined time, the saved device identification information is used. A data transfer control system for continuing interrupted data transfer.
対象とするデータ転送制御システムにおいて、 前記デバイスの識別情報,前記デバイスに発行しようと
するコマンドおよび前記デバイスの接続状態を記憶する
記憶手段と、 前記デバイスが接続されると、当該デバイスの識別情報
をデバイスから取得して前記記憶されている識別情報と
比較し、不一致なら新規接続であるため前記記憶された
コマンドを消去し、また一致なら再接続であるため切断
タイマを停止するとともにコマンドの再送指示を行うデ
バイス接続処理手段と、 アプリケーションからの前記デバイスに対するデータ転
送要求か、または前記再送指示により起動され、前記記
憶手段の記憶内容によって、当該デバイスが接続されて
いれば当該コマンドを実行して前記記憶されたコマンド
を消去し、また接続されていないが識別情報が記憶され
ていれば「実行中」のステータスを前記アプリケーショ
ンに返却するコマンド実行処理手段と、 デバイスが切断されると前記接続状態を未接続とし、切
断タイマ処理手段を起動するデバイス切断処理手段と、 タイムアウトする時間を設定してタイムアウトを待ち、
この間に前記デバイス接続処理手段が実行されると前記
記憶されたコマンドを廃棄し、また前記タイムアウトが
発生すると前記記憶されたデバイスの識別情報を消去す
る切断タイマ処理手段とを備えたことを特徴とするデー
タ転送制御システム。3. A data transfer control system in which a hot-swappable device is a target of data transfer, a storage means for storing identification information of the device, a command to be issued to the device, and a connection state of the device. When the device is connected, the identification information of the device is obtained from the device and compared with the stored identification information.If there is no match, the stored command is deleted because it is a new connection, and if there is a match, Device connection processing means for stopping the disconnection timer and instructing a command retransmission because of the reconnection, and a data transfer request to the device from an application or activated by the retransmission instruction, and according to the storage content of the storage means, If the device is connected, execute the command and execute the command. Command execution processing means for erasing a command that has been disconnected, and returning a status of "executing" to the application if the connection information is not connected but identification information is stored, and the connection state is not connected when the device is disconnected. The device disconnection processing means for activating the disconnection timer processing means, the time-out period being set, and waiting for the timeout,
Disconnection timer processing means for discarding the stored command when the device connection processing means is executed during this time, and for deleting the stored device identification information when the timeout occurs. Data transfer control system.
までの時間を外部から設定可能にしたことを特徴とする
請求項2または3記載のデータ転送制御システム。4. The data transfer control system according to claim 2, wherein a time from disconnection of the device to reconnection of the device can be externally set.
シリアル番号であることを特徴とする請求項2ないし4
のいずれかに記載のデータ転送制御システム。5. The device according to claim 2, wherein the identification information of the device is a serial number of the device.
The data transfer control system according to any one of the above.
対象とするデータ転送制御方法において、 前記デバイスの識別情報,前記デバイスに発行しようと
するコマンドおよび前記デバイスの接続状態を記憶する
記憶手順と、 前記デバイスが接続されると、当該デバイスの識別情報
をデバイスから取得して前記記憶されている識別情報と
比較し、不一致なら新規接続であるため前記記憶された
コマンドを消去し、また一致なら再接続であるため切断
タイマを停止するとともにコマンドの再送指示を行うデ
バイス接続処理手順と、 アプリケーションからの前記デバイスに対するデータ転
送要求か、または前記再送指示により起動され、前記記
憶された内容によって、当該デバイスが接続されていれ
ば当該コマンドを実行して前記記憶されたコマンドを消
去し、また接続されていないが識別情報が記憶されてい
れば「実行中」のステータスを前記アプリケーションに
返却するコマンド実行処理手順と、 デバイスが切断されると前記接続状態を未接続とし、切
断タイマ処理理手順を起動するデバイス切断処理手順
と、 タイムアウトする時間を設定してタイムアウトを待ち、
この間に前記デバイス接続処理手順が実行されると前記
記憶されたコマンドを廃棄し、また前記タイムアウトが
発生すると前記記憶されたデバイスの識別情報を消去す
る切断タイマ処理手順とを有することを特徴とするデー
タ転送制御方法。6. A data transfer control method in which a hot-swappable device is subjected to data transfer, a storage procedure for storing identification information of the device, a command to be issued to the device, and a connection state of the device. When the device is connected, the identification information of the device is obtained from the device and compared with the stored identification information.If there is no match, the stored command is deleted because it is a new connection, and if there is a match, The device connection processing procedure for stopping the disconnection timer and instructing a command retransmission because of the reconnection, and a data transfer request from the application to the device, or activated by the retransmission instruction and according to the stored content, If the device is connected, execute the command to execute the stored command. A command execution processing procedure for erasing the password and returning a status of “executing” to the application if the connection information is not connected but the identification information is stored, and the connection state is set to unconnected when the device is disconnected. , Set the device disconnection processing procedure that starts the disconnection timer processing procedure, and the time-out period, wait for the timeout,
A disconnection timer processing procedure for discarding the stored command when the device connection processing procedure is executed during this time, and for deleting the stored device identification information when the timeout occurs. Data transfer control method.
までの時間を外部から設定する手順を付加したことを特
徴とする請求項6記載のデータ転送制御方法。7. The data transfer control method according to claim 6, further comprising a step of externally setting a time from disconnection of said device to reconnection of said device.
対象とするデータ転送制御方法であって、 前記デバイスの識別情報,前記デバイスに発行しようと
するコマンドおよび前記デバイスの接続状態を記憶する
記憶手順と、 前記デバイスが接続されると、当該デバイスの識別情報
をデバイスから取得して前記記憶されている識別情報と
比較し、不一致なら新規接続であるため前記記憶された
コマンドを消去し、また一致なら再接続であるため切断
タイマを停止するとともにコマンドの再送指示を行うデ
バイス接続処理手順と、 アプリケーションからの前記デバイスに対するデータ転
送要求か、または前記再送指示により起動され、前記記
憶された内容によって、当該デバイスが接続されていれ
ば当該コマンドを実行して前記記憶されたコマンドを消
去し、また接続されていないが識別情報が記憶されてい
れば「実行中」のステータスを前記アプリケーションに
返却するコマンド実行処理手順と、 デバイスが切断されると前記接続状態を未接続とし、切
断タイマ処理理手順を起動するデバイス切断処理手順
と、 タイムアウトする時間を設定してタイムアウトを待ち、
この間に前記デバイス接続処理手順が実行されると前記
記憶されたコマンドを廃棄し、また前記タイムアウトが
発生すると前記記憶されたデバイスの識別情報を消去す
る切断タイマ処理手順とを有することを特徴とするデー
タ転送制御方法をコンピュータに実行させるためのプロ
グラムを記憶したコンピュータ読み込み可能な記録媒
体。8. A data transfer control method in which a hot-swappable device is a target of data transfer, wherein the storage device stores identification information of the device, a command to be issued to the device, and a connection state of the device. Procedure, when the device is connected, obtains the identification information of the device from the device, compares the identification information with the stored identification information, and if there is a mismatch, deletes the stored command because it is a new connection; and If they match, it is a reconnection, so that the disconnection timer is stopped and a command for retransmitting the command is sent to the device connection processing procedure. If the device is connected, execute the command to execute the stored command. A command execution processing procedure for erasing the password and returning a status of “executing” to the application if the connection information is not connected but the identification information is stored, and the connection state is set to unconnected when the device is disconnected. , Set the device disconnection processing procedure that starts the disconnection timer processing procedure, and the time-out period, wait for the timeout,
A disconnection timer processing procedure for discarding the stored command when the device connection processing procedure is executed during this time, and for deleting the stored device identification information when the timeout occurs. A computer-readable recording medium storing a program for causing a computer to execute the data transfer control method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP11069992A JP2000267951A (en) | 1999-03-16 | 1999-03-16 | Data transfer control system and its method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP11069992A JP2000267951A (en) | 1999-03-16 | 1999-03-16 | Data transfer control system and its method |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2000267951A true JP2000267951A (en) | 2000-09-29 |
Family
ID=13418690
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP11069992A Pending JP2000267951A (en) | 1999-03-16 | 1999-03-16 | Data transfer control system and its method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2000267951A (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2003008683A (en) * | 2001-06-18 | 2003-01-10 | Nec Corp | Cellular phone apparatus with usb reconnection function, and communication recovery method of the device |
WO2005111772A2 (en) | 2004-05-13 | 2005-11-24 | Matsushita Electric Industrial Co., Ltd. | An information processing apparatus, an integrated circuit, a data transfer controlling method, a data transfer controlling program, a program storage medium, a program transmission medium and a data storage medium |
JP2009181336A (en) * | 2008-01-30 | 2009-08-13 | Ricoh Co Ltd | Image forming apparatus, print control method, print control program, and recording medium |
JP2009276070A (en) * | 2008-05-12 | 2009-11-26 | Shimadzu Corp | Material testing machine |
JP2013142937A (en) * | 2012-01-06 | 2013-07-22 | Canon Inc | Electronic equipment and control method |
CN111190830A (en) * | 2019-12-31 | 2020-05-22 | 东莞华贝电子科技有限公司 | Method and device for automatically identifying state of computer port and starting test program |
-
1999
- 1999-03-16 JP JP11069992A patent/JP2000267951A/en active Pending
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2003008683A (en) * | 2001-06-18 | 2003-01-10 | Nec Corp | Cellular phone apparatus with usb reconnection function, and communication recovery method of the device |
WO2005111772A2 (en) | 2004-05-13 | 2005-11-24 | Matsushita Electric Industrial Co., Ltd. | An information processing apparatus, an integrated circuit, a data transfer controlling method, a data transfer controlling program, a program storage medium, a program transmission medium and a data storage medium |
WO2005111772A3 (en) * | 2004-05-13 | 2006-07-20 | Matsushita Electric Ind Co Ltd | An information processing apparatus, an integrated circuit, a data transfer controlling method, a data transfer controlling program, a program storage medium, a program transmission medium and a data storage medium |
US7707327B2 (en) | 2004-05-13 | 2010-04-27 | Panasonic Corporation | Information processing apparatus, an integrated circuit, a data transfer controlling method, a data transfer controlling program, a program storage medium, a program transmission medium and a data storage medium |
JP2009181336A (en) * | 2008-01-30 | 2009-08-13 | Ricoh Co Ltd | Image forming apparatus, print control method, print control program, and recording medium |
JP2009276070A (en) * | 2008-05-12 | 2009-11-26 | Shimadzu Corp | Material testing machine |
JP2013142937A (en) * | 2012-01-06 | 2013-07-22 | Canon Inc | Electronic equipment and control method |
CN111190830A (en) * | 2019-12-31 | 2020-05-22 | 东莞华贝电子科技有限公司 | Method and device for automatically identifying state of computer port and starting test program |
CN111190830B (en) * | 2019-12-31 | 2023-05-16 | 东莞华贝电子科技有限公司 | Method and device for automatically identifying computer port state and starting test program |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10551906B2 (en) | Methods and apparatus for running and booting inter-processor communication link between independently operable processors | |
TW552780B (en) | USB communication control apparatus, USB communication system and USB communication control method | |
US6353866B1 (en) | Apparatus and method for initializing a universal serial bus device | |
US7069373B2 (en) | USB endpoint controller flexible memory management | |
US6904022B2 (en) | Data transfer control device, information storage medium and electronic equipment | |
JP2000267951A (en) | Data transfer control system and its method | |
US20030145150A1 (en) | Interface conversion system and data transfer method | |
CN118708128A (en) | Solid state hard disk data transmission rate control method and solid state hard disk | |
JP2006190257A (en) | Data transfer apparatus and data transfer method | |
JP5010065B2 (en) | Microcomputer | |
CN110990313B (en) | A method, device and storage medium for I3C bus processing clock stretching | |
JP2003008683A (en) | Cellular phone apparatus with usb reconnection function, and communication recovery method of the device | |
CN115706437A (en) | Communication method and apparatus, medium, and program for supplying power based on universal serial bus | |
EP1179907A2 (en) | Data communication apparatus and method with error correction mode | |
CN119065730B (en) | A self-adaptive storage system and method | |
JP4988982B2 (en) | Microcomputer control method | |
JP2002358177A (en) | Image forming apparatus, serial communication method for the apparatus, program for allowing computer to perform the method and recording medium with the program recorded thereon | |
JP7117674B2 (en) | Data transfer system and system host | |
JP3867762B2 (en) | Decryption device | |
JP3580081B2 (en) | Facsimile machine | |
JP3157794B2 (en) | Peripheral control processor | |
JPH10222252A (en) | Information processor and method for initializing its peripheral equipment | |
JP2004094494A (en) | Storage medium processor and its control method | |
JPH09102187A (en) | Flexible disk device with infrared communication interface | |
JPH1139240A (en) | Circuit and method for controlling transmission-reception buffer, and recording medium for recording control program for the circuit |