JP2014168144A - Communication method and switching hub - Google Patents
Communication method and switching hub Download PDFInfo
- Publication number
- JP2014168144A JP2014168144A JP2013039045A JP2013039045A JP2014168144A JP 2014168144 A JP2014168144 A JP 2014168144A JP 2013039045 A JP2013039045 A JP 2013039045A JP 2013039045 A JP2013039045 A JP 2013039045A JP 2014168144 A JP2014168144 A JP 2014168144A
- Authority
- JP
- Japan
- Prior art keywords
- communication
- host device
- target device
- target
- data
- 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
Images
Landscapes
- Small-Scale Networks (AREA)
Abstract
Description
本発明は、USB(Universal Serial Bus)規格に従ってデータの送受信を行うための通信方法、スイッチングハブ、及びデータ転送システムに関し、特に複数のターゲット装置がスイッチングハブを介してホスト装置とデータの送受信を行うための通信方法に適用して有効な技術に関する。 The present invention relates to a communication method, a switching hub, and a data transfer system for transmitting / receiving data in accordance with a USB (Universal Serial Bus) standard, and more particularly, a plurality of target devices transmit / receive data to / from a host device via the switching hub. The present invention relates to a technology that is effective when applied to a communication method.
パソコンや家庭用のマルチメディア機器などのホスト装置にハードディスクドライブやメモリカードリーダ、プリンタ、デジタルカメラ等の周辺装置(以下、ターゲット装置とも称する。)を接続する汎用インターフェースとして、USBが知られている。USBでは、ハブを用いることにより、ホスト装置の1つのポートに複数のターゲット装置を接続して通信することができる。このようなUSB規格による通信(以下、単にUSB通信とも称する。)を行うデータ転送システムにおけるハブに関する従来技術として、例えば特許文献1に開示がある。
USB is known as a general-purpose interface for connecting a peripheral device (hereinafter also referred to as a target device) such as a hard disk drive, a memory card reader, a printer, or a digital camera to a host device such as a personal computer or a home multimedia device. . In USB, by using a hub, a plurality of target devices can be connected to one port of a host device to communicate. For example,
従来から、USB通信以外の分野において、1つのホスト装置と複数の周辺装置との間で通信を行う方法が知られている。例えば、特許文献2には、同報通信により、マスタ装置と複数のスレーブ装置との間で通信を行うマスタ/スレーブ通信方法が開示されている。同文献には、マスタ装置が複数のスレーブ装置に対して制御及び監視を行う場合に、マスタ装置が同報通信により監視・制御命令を各スレーブ装置に対して送信し、各スレーブ装置はそれに対する応答を前記マスタ装置が指定した中継装置に送信し、中継装置が各スレーブ装置からの応答を前記マスタ装置に送信する方法が開示されている。
Conventionally, a method for performing communication between one host device and a plurality of peripheral devices in a field other than USB communication is known. For example,
これに対し、USB通信のデータ転送システムでは、ホスト装置が各ターゲット装置に順次問い合わせを行うポーリングによって、ホスト装置と各ターゲット装置間の通信が実現される。 On the other hand, in the USB communication data transfer system, communication between the host device and each target device is realized by polling in which the host device sequentially inquires each target device.
上述したように、USB規格による通信(以下、単に、USB通信とも称する。)はホスト装置主導の通信方式であるため、例えば、一つのターゲット装置がホスト装置と通信を行っている期間は、他のターゲット装置は通信を行うことができない、又は、通信ができても制限される。例えば、3つのターゲット装置がハブを介してホスト装置に接続されているデータ転送システムにおいて、1つのターゲット装置がホスト装置との間で大容量のデータをやり取りしている場合を考える。データ転送のスケジュールは、所定の時間毎に反復される夫々のフレームによって区切られ、そのフレーム内で夫々のターゲット装置に転送時間が割り当てられる。この場合、従来のUSB通信では、ホスト装置は、大容量の転送データを扱う前記1つのターゲット装置には長い転送時間を割り当て、残りの2つのターゲット装置には短い転送時間を割り当てる。そのため、前記残りの2つのターゲット装置は1つのフレームにおいて転送できるデータ量が制限され、目的とするデータ転送を完了するのに必要なトランザクション数が増加する。また、1つのトランザクションでは、トークンパケットの転送、データパケットの転送、ハンドシェイクパケットの転送という手順で通信が行われるため、前記残りの2つのターゲット装置の転送すべきデータの総データ量が少ない場合であっても、トランザクション数が増加すれば、通信のオーバーヘッドが大きくなり、スループットが悪化する。これにより、USB通信の通信時間が長くなり、レスポンスが悪くなるという問題があった。 As described above, communication according to the USB standard (hereinafter also simply referred to as USB communication) is a communication method led by the host device. For example, a period during which one target device communicates with the host device Target devices cannot communicate or are restricted even if they can communicate. For example, in a data transfer system in which three target devices are connected to a host device via a hub, consider a case where one target device exchanges a large amount of data with the host device. The data transfer schedule is delimited by each frame repeated every predetermined time, and a transfer time is allocated to each target device within the frame. In this case, in conventional USB communication, the host device assigns a long transfer time to the one target device that handles large-capacity transfer data, and assigns a short transfer time to the remaining two target devices. Therefore, the amount of data that can be transferred in one frame in the remaining two target devices is limited, and the number of transactions required to complete the target data transfer increases. In addition, since communication is performed in one transaction by a procedure of token packet transfer, data packet transfer, and handshake packet transfer, the total amount of data to be transferred by the remaining two target devices is small. However, if the number of transactions increases, the communication overhead increases and the throughput deteriorates. As a result, there is a problem that the communication time of USB communication becomes longer and the response becomes worse.
このような課題を解決するための手段等を以下に説明するが、その他の課題と新規な特徴は本明細書の記述及び添付図面から明らかになるであろう。 Means for solving such problems will be described below, but other problems and novel features will become apparent from the description of the present specification and the accompanying drawings.
本願において開示される実施の形態のうち代表的なものの概要を簡単に説明すれば下記のとおりである。 An outline of representative ones of the embodiments disclosed in the present application will be briefly described as follows.
すなわち、本通信方法は、ホスト装置と、n個のターゲット装置とがスイッチングハブを介してUSB通信を行うための通信方法であって、ターゲット装置毎にホスト装置とデータの送受信が可能な第1通信モードと、複数のターゲット装置のデータをまとめてホスト装置に送信可能な第2通信モードとが切り替え可能にされる。本通信方法は、以下の処理を含む。ホスト装置が一のターゲット装置と通信を行うとき、他のターゲット装置に対して通信モードを指示する処理。第2通信モードが指示された場合に、他のターゲット装置が夫々の転送データを1つのターゲット装置の記憶部にまとめて格納する処理。前記通信の完了後、前記1つのターゲット装置が、自らの転送データと前記格納した転送データをまとめてホスト装置に送信する処理。 That is, this communication method is a communication method for performing USB communication between a host device and n target devices via a switching hub, and is a first method capable of transmitting and receiving data to and from the host device for each target device. The communication mode and the second communication mode in which data of a plurality of target devices can be collectively transmitted to the host device can be switched. This communication method includes the following processes. When the host device communicates with one target device, a process of instructing the communication mode to other target devices. When the second communication mode is instructed, the other target devices collectively store the respective transfer data in the storage unit of one target device. After the completion of the communication, the one target device collectively transmits its own transfer data and the stored transfer data to the host device.
本願において開示される実施の形態のうち代表的なものによって得られる効果を簡単に説明すれば下記のとおりである。 The effects obtained by the representative ones of the embodiments disclosed in the present application will be briefly described as follows.
すなわち、ホスト装置に複数のターゲット装置が接続されたデータ転送システムにおいて、USB通信の通信時間を短縮することができる。 In other words, in a data transfer system in which a plurality of target devices are connected to a host device, the communication time for USB communication can be shortened.
1.実施の形態の概要
先ず、本願において開示される代表的な実施の形態について概要を説明する。代表的な実施の形態についての概要説明で括弧を付して参照する図面中の参照符号はそれが付された構成要素の概念に含まれるものを例示するに過ぎない。
1. First, an outline of a typical embodiment disclosed in the present application will be described. Reference numerals in the drawings referred to in parentheses in the outline description of the representative embodiments merely exemplify what are included in the concept of the components to which the reference numerals are attached.
〔1〕(1つのUSBターゲット装置がホスト装置と通信を行っている期間に他のUSBターゲット装置間でデータをまとめ、上記通信後にまとめたデータをホスト装置に送信する通信方法)
本願の代表的な実施の形態に係る通信方法は、ホスト装置(11)と、一時的にデータを格納するための記憶部(101)を備えるn個(nは3以上の整数)のターゲット装置(TGT_1〜TGT_3)とが、スイッチングハブ(12)を介してUSB規格に従ったデータの送受信を行うための通信方法である。前記ホスト装置と前記n個のターゲット装置とは、前記ターゲット装置毎に前記ホスト装置とデータの送受信が可能な第1通信モードと、複数のターゲット装置のデータをまとめてホスト装置に送信可能な第2通信モードとを切り替えて通信可能とされる。本通信方法は、以下の処理を含む。前記ホスト装置が、一のターゲット装置(TGT_3)と通信を行うとき、前記一のターゲット装置以外の他のターゲット装置(TGT_1、TGT_2)に対して通信モードを指示する第1処理(S101、S103)。前記ホスト装置が、前記一のターゲット装置と通信を開始する第2処理(S105)。前記第1処理において前記第2通信モードが指示された場合に、前記他のターゲット装置が、相互に通信を行うことにより、夫々が保有する前記ホスト装置に転送するための転送データを1つの前記他のターゲット装置内の前記記憶部にまとめて格納する第3処理(S110)。前記ホスト装置と前記一のターゲット装置の通信の完了後、前記第3処理において前記転送データを前記記憶部にまとめて格納したターゲット装置(TGT_1)が、自らの転送データと前記記憶部に格納した転送データとをまとめて前記ホスト装置に送信する第4処理(S115)。
[1] (Communication method in which data is collected between other USB target devices while one USB target device is communicating with the host device, and the collected data is transmitted to the host device after the communication)
A communication method according to a representative embodiment of the present application includes a host device (11) and n (n is an integer of 3 or more) target devices each including a storage unit (101) for temporarily storing data. (TGT_1 to TGT_3) is a communication method for transmitting and receiving data according to the USB standard via the switching hub (12). The host device and the n target devices are a first communication mode capable of transmitting and receiving data to and from the host device for each target device, and a first communication mode in which data of a plurality of target devices can be collectively transmitted to the host device. Communication is possible by switching between the two communication modes. This communication method includes the following processes. When the host device communicates with one target device (TGT_3), a first process (S101, S103) for instructing a communication mode to other target devices (TGT_1, TGT_2) other than the one target device . A second process in which the host device starts communication with the one target device (S105). When the second communication mode is instructed in the first process, the other target devices communicate with each other, thereby transferring one transfer data to be transferred to the host device held by each of the other target devices. Third processing (S110) for storing together in the storage unit in another target device. After the communication between the host device and the one target device is completed, the target device (TGT_1) that collectively stores the transfer data in the storage unit in the third process stores the transfer data and its own storage unit in the storage unit. Fourth processing (S115) for transmitting the transfer data together to the host device.
これによれば、前記他のターゲット装置の夫々がホスト装置と通信を確立してデータを転送する場合に比べて、前記他のターゲット装置の全ての転送データの送信が完了するのに必要なトランザクション数が少なくなるので、転送におけるオーバーヘッドが小さくなり、スループットが向上する。また、USB規格では、スイッチングハブに接続されたターゲット装置の通信スピードが相異する場合、通信スピードの一番遅いターゲット装置に合わせて通信を行わなくてはならないが、本通信方法では、記憶部に転送データをまとめて蓄積したターゲット装置が取り得る最速の通信スピードによってデータ通信を行うことが可能となる。したがって、本通信方法によれば、ホスト装置とn個のターゲット装置とがスイッチングハブを介して接続されるデータ転送システムにおいて、USB通信の通信時間を短縮することができる。 According to this, compared with the case where each of the other target devices establishes communication with the host device and transfers data, the transaction required to complete transmission of all transfer data of the other target device. Since the number is reduced, overhead in transfer is reduced and throughput is improved. Further, in the USB standard, when the communication speeds of the target devices connected to the switching hub are different, communication must be performed in accordance with the target device having the slowest communication speed. Thus, it is possible to perform data communication at the fastest communication speed that can be taken by the target device that collectively stores the transfer data. Therefore, according to this communication method, the communication time of USB communication can be shortened in a data transfer system in which a host device and n target devices are connected via a switching hub.
〔2〕(バッファの記憶容量が最も大きいターゲット装置にデータを蓄積)
項1の通信方法において、前記1つの前記他のターゲット装置は、前記他のターゲット装置の中で前記記憶部の記憶容量が最も大きくされる。
[2] (Data is stored in the target device with the largest buffer storage capacity)
In the communication method according to
これによれば、より多くのデータを前記記憶部に格納することができるから、スループットを更に向上させることができる。 According to this, since more data can be stored in the storage unit, the throughput can be further improved.
〔3〕(記憶容量が最も大きいターゲット装置を判別し、転送データを送信)
項2の通信方法において、前記第3処理は、以下の処理を含む。前記他のターゲット装置が、夫々の保有する前記記憶部の記憶容量の大きさを示す記憶容量の情報を相互に送受信する第5処理(S106、S107)。前記他のターゲット装置が、前記記憶容量の情報に基づいて、自らの前記記憶部の記憶容量が最も大きいか否かを判別し、前記記憶容量が最も大きいと判断したターゲット装置が、それ以外のターゲット装置に対して、転送データの蓄積が可能であることを通知する第6処理(S108)。前記第6処理の通知を受けたターゲット装置が、前記ホスト装置に転送するための転送データを前記記憶容量が最も大きいと判断したターゲット装置に送信し、前記記憶容量が最も大きいと判断したターゲット装置が、受信した前記転送データを前記記憶部に格納する第7処理(S110)。
[3] (Identify the target device with the largest storage capacity and send the transfer data)
In the communication method according to
これによれば、最も大きな記憶容量の記憶部を有するターゲット装置を容易に判別することができ、判別されたターゲット装置に対して、他のターゲット装置が転送データを送信することが容易となる。 According to this, it is possible to easily determine the target device having the storage unit with the largest storage capacity, and it becomes easy for another target device to transmit the transfer data to the determined target device.
〔4〕(所定時間内に送信可能なデータを蓄積)
項3の通信方法は、前記第1処理において、前記ホスト装置が、前記他のターゲット装置に対して、前記ホスト装置と通信が可能になるまでの待機時間を示す情報を更に送信する。前記第7処理において、前記それ以外のターゲット装置は、前記待機時間を示す情報に基づいて、前記ホスト装置と前記一のターゲット装置の通信が完了するまでに送信可能なデータ量を算出するとともに、前記算出したデータ量に応じた前記転送データを、前記記憶容量が最も大きいと判断したターゲット装置に対して送信するデータとする。
[4] (Accumulate data that can be transmitted within a specified time)
In the communication method according to
これによれば、前記ホスト装置と前記一のターゲット装置が通信を行っている期間に、より多くの転送データを前記記憶部に格納することが可能となり、スループットの更なる向上に資する。 According to this, it is possible to store more transfer data in the storage unit during a period in which the host device and the one target device are communicating, which contributes to further improvement of throughput.
〔5〕(予測トランザクション数)
項4の通信方法において、前記待機時間を示す情報は、前記ホスト装置と前記一のターゲット装置との通信で予定されているトランザクション数の情報を含む。
[5] (Predicted number of transactions)
In the communication method according to Item 4, the information indicating the waiting time includes information on the number of transactions scheduled for communication between the host device and the one target device.
〔6〕(予測時間)
項4の通信方法において、前記待機時間を示す情報は、前記ホスト装置と前記一のターゲット装置との通信に要する予測時間の情報を含む。
[6] (Predicted time)
In the communication method according to Item 4, the information indicating the standby time includes information on an estimated time required for communication between the host device and the one target device.
〔7〕(1つのUSBターゲット装置がホスト装置と通信を行っている期間に他のUSBターゲット装置のデータをスイッチングハブのバッファメモリにまとめて格納し、上記通信後にまとめたデータをホスト装置に送信する通信方法)
本願の代表的な実施の形態に係る通信方法は、ホスト装置(11)と、n個(nは3以上の整数)のターゲット装置(TGT_1A〜TGT_3A)とが、スイッチングハブ(22)を介してUSB規格に従ったデータの送受信を行うための通信方法である。前記ホスト装置と前記n個のターゲット装置とは、前記ターゲット装置毎に前記ホスト装置とデータの送受信が可能な第1通信モードと、複数のターゲット装置のデータをまとめてホスト装置に送信可能な第2通信モードとを切り替えて通信可能とされる。前記スイッチングハブは、一次的にデータの格納が可能な記憶部(225)を含む。本通信方法は、以下の処理を含む。前記ホスト装置が、一のターゲット装置と通信を行うとき、前記一のターゲット装置以外の他のターゲット装置と前記スイッチングハブに対して通信モードを指示する第1処理(S301、S303、S305)。前記ホスト装置が、前記一のターゲット装置と通信を開始する第2処理(S307)。前記第1処理において前記第2通信モードが指示された場合に、前記他のターゲット装置が、前記スイッチングハブと通信を行うことにより、夫々の前記他のターゲット装置が保有する前記ホスト装置に転送するための転送データを前記スイッチングハブ内の前記記憶部にまとめて格納する第3処理(S308〜S313)。前記ホスト装置と前記一のターゲット装置の通信の完了後、前記スイッチングハブが前記記憶部に格納した前記転送データをまとめて前記ホスト装置に送信する第4処理(S320)。
[7] (When one USB target device is communicating with the host device, the data of the other USB target devices are stored together in the buffer memory of the switching hub, and the combined data is transmitted to the host device after the communication. Communication method)
In the communication method according to the representative embodiment of the present application, a host device (11) and n (n is an integer of 3 or more) target devices (TGT_1A to TGT_3A) are connected via a switching hub (22). This is a communication method for transmitting and receiving data according to the USB standard. The host device and the n target devices are a first communication mode capable of transmitting and receiving data to and from the host device for each target device, and a first communication mode in which data of a plurality of target devices can be collectively transmitted to the host device. Communication is possible by switching between the two communication modes. The switching hub includes a storage unit (225) capable of temporarily storing data. This communication method includes the following processes. When the host device communicates with one target device, a first process (S301, S303, S305) for instructing a communication mode to a target device other than the one target device and the switching hub. A second process in which the host device starts communication with the one target device (S307). When the second communication mode is instructed in the first process, the other target device communicates with the switching hub and transfers to the host device held by each of the other target devices. 3rd processing (S308-S313) which stores the transfer data for this in the said memory | storage part in the said switching hub collectively. After the communication between the host device and the one target device is completed, a fourth process (S320) in which the switching hub collectively transmits the transfer data stored in the storage unit to the host device.
本通信方法では、前記一のターゲット装置と前記ホスト装置が通信を行っている期間に、前記スイッチングハブが、擬似的なホスト装置として、他のホスト装置からの転送データを蓄積するとともに、上記通信後に蓄積した転送データをホスト装置にまとめて送信する。これによれば、前記他のターゲット装置の夫々がホスト装置と通信を確立してデータを転送する場合に比べて、前記他のターゲット装置の全ての転送データの送信が完了するのに必要なトランザクション数が少なくなるので、転送におけるオーバーヘッドが小さくなり、スループットが向上する。また、USB規格では、スイッチングハブに接続されたターゲット装置の通信スピードが相異する場合、通信スピードの一番遅いターゲット装置に合わせて通信を行わなくてはならないが、本通信方法では、スイッチングハブが取り得る最速の通信スピードによってホスト装置とデータ通信を行うことが可能となる。したがって、本通信方法によれば、ホスト装置とn個のターゲット装置とがスイッチングハブを介して接続されるデータ転送システムにおいて、USB通信の通信時間を短縮することができる。 In the communication method, the switching hub accumulates transfer data from another host device as a pseudo host device during a period in which the one target device and the host device are communicating, and the communication The transfer data stored later is collectively transmitted to the host device. According to this, compared with the case where each of the other target devices establishes communication with the host device and transfers data, the transaction required to complete transmission of all transfer data of the other target device. Since the number is reduced, overhead in transfer is reduced and throughput is improved. In the USB standard, when the communication speeds of the target devices connected to the switching hub are different, communication must be performed in accordance with the target device having the slowest communication speed. It is possible to perform data communication with the host device at the fastest communication speed possible. Therefore, according to this communication method, the communication time of USB communication can be shortened in a data transfer system in which a host device and n target devices are connected via a switching hub.
〔8〕(スイッチングハブとターゲット装置との間の通信方法の詳細)
項7の通信方法において、前記第3処理は、前記スイッチングハブが、前記転送データの蓄積が可能であることを前記他のターゲット装置に通知する第5処理(S308、S310)と、前記他のターゲット装置が前記転送データを前記スイッチングハブに送信し、前記スイッチングハブが受信した前記転送データを前記記憶部に蓄積する第6処理(S312、S313)とを含む。
[8] (Details of communication method between switching hub and target device)
In the communication method according to Item 7, the third process includes a fifth process (S308, S310) in which the switching hub notifies the other target device that the transfer data can be stored, and the other process. Including a sixth process (S312 and S313) in which the target device transmits the transfer data to the switching hub and accumulates the transfer data received by the switching hub in the storage unit.
これによれば、ホスト装置を介さずにスイッチングハブとターゲット装置間で通信を実行することが容易となる。 This facilitates communication between the switching hub and the target device without using the host device.
〔9〕(所定時間内に送信可能なデータを蓄積)
項8の通信方法は、前記第1処理において、前記ホスト装置が、前記他のターゲット装置と前記スイッチングハブに対して、前記ホスト装置と通信が可能になるまでの待機時間を示す情報を更に送信する。前記第6処理において、前記他のターゲット装置は、前記待機時間を示す情報に基づいて、前記ホスト装置と前記一のターゲット装置の通信が完了するまでに送信可能なデータ量を算出するとともに、前記算出したデータ量に応じた前記転送データを、前記スイッチングハブに送信するデータとする。
[9] (Accumulate data that can be transmitted within a predetermined time)
In the communication method according to item 8, in the first process, the host device further transmits information indicating a waiting time until communication with the host device becomes possible to the other target device and the switching hub. To do. In the sixth process, the other target device calculates the amount of data that can be transmitted before the communication between the host device and the one target device is completed based on the information indicating the standby time. The transfer data corresponding to the calculated data amount is data to be transmitted to the switching hub.
これによれば、前記ホスト装置と前記一のターゲット装置が通信を行っている期間に、より多くの転送データを前記記憶部に格納することが可能となり、スループットの更なる向上に資する。 According to this, it is possible to store more transfer data in the storage unit during a period in which the host device and the one target device are communicating, which contributes to further improvement of throughput.
〔10〕(予測トランザクション数)
項9の通信方法において、前記待機時間を示す情報は、前記ホスト装置と前記一のターゲット装置との通信で予定されているトランザクション数の情報を含む。
[10] (Predicted number of transactions)
In the communication method according to item 9, the information indicating the waiting time includes information on the number of transactions scheduled for communication between the host device and the one target device.
〔11〕(予測時間)
項9の通信方法において、前記待機時間を示す情報は、前記ホスト装置と前記一のターゲット装置との通信に要する予測時間の情報を含む。
[11] (Predicted time)
In the communication method according to Item 9, the information indicating the standby time includes information on an estimated time required for communication between the host device and the one target device.
〔12〕(スイッチングハブ)
本願の代表的な実施の形態に係るスイッチングハブ(22)は、USB規格に従って通信が可能なスイッチングハブである。本スイッチングハブは、ホスト装置(11)と接続するための第1入出力ポート(121)と、ターゲット装置(TGT_1A〜TGT_3A)と接続するためのn個(nは3以上の整数)の第2入出力ポート(123〜125)と、を有する。本スイッチングハブは更に、前記第1入出力ポートと前記第2入出力ポートとの間の接続を切り替えることにより、前記第1入出力ポートに接続された前記ホスト装置と前記第2入出力ポートに接続された前記ターゲット装置との間の通信を制御するための通信制御部(220、122)と、記憶部(225)とを有する。前記通信制御部は、前記第1入出力ポートと一の前記第2入出力ポートとの接続を確立しているとき、前記ホスト装置に転送するための転送データが他の前記第2入出力ポートに供給された場合には、前記転送データを前記記憶部にまとめて格納する。更に前記通信制御部は、前記第1入出力ポートと前記一の前記第2入出力ポートとの接続の解除後に、前記記憶部に格納した転送データをまとめて前記第1入出力ポートから出力することが可能にされる。
[12] (Switching hub)
The switching hub (22) according to the representative embodiment of the present application is a switching hub capable of communication according to the USB standard. This switching hub has a first input / output port (121) for connection to the host device (11) and n second (n is an integer of 3 or more) second for connection to the target devices (TGT_1A to TGT_3A). Input / output ports (123 to 125). The switching hub further switches the connection between the first input / output port and the second input / output port to connect the host device connected to the first input / output port and the second input / output port. It has a communication control part (220,122) for controlling communication between the said connected target apparatuses, and a memory | storage part (225). When the communication control unit establishes a connection between the first input / output port and one second input / output port, transfer data to be transferred to the host device is transferred to the other second input / output port. The transfer data is stored together in the storage unit. Further, the communication control unit collectively outputs the transfer data stored in the storage unit from the first input / output port after releasing the connection between the first input / output port and the one second input / output port. Is made possible.
これによれば、第1入出力ポートに接続する第2入出力ポートを順次切り替えながら、夫々の前記他のターゲット装置とホスト装置との間の通信を構築する従来のスイッチングハブに比べて、前記他のターゲット装置の全ての転送データの送信が完了するのに必要なトランザクション数が少なくなるので、転送におけるオーバーヘッドが小さくなり、スループットが向上する。また、USB規格では、スイッチングハブに接続されたターゲット装置の通信スピードが相異する場合、通信スピードの一番遅いターゲット装置に合わせて通信を行わなくてはならないが、本スイッチングハブによれば、スイッチングハブが取り得る最速の通信スピードによってデータ通信を行うことが可能となる。したがって、本スイッチングハブによれば、USB通信の通信時間を短縮することができる。 According to this, compared with the conventional switching hub that constructs communication between each of the other target devices and the host device while sequentially switching the second input / output port connected to the first input / output port. Since the number of transactions required to complete transmission of all transfer data of other target devices is reduced, overhead in transfer is reduced and throughput is improved. In addition, in the USB standard, when the communication speed of the target device connected to the switching hub is different, communication must be performed in accordance with the target device having the slowest communication speed. Data communication can be performed at the fastest communication speed that the switching hub can take. Therefore, according to this switching hub, the communication time of USB communication can be shortened.
〔13〕(データ転送システム)
本願の代表的な実施の形態に係るデータ転送システム(1)は、ホスト装置(11)と、n個(nは3以上の整数)のターゲット装置(TGT_1〜TGT_3)を有する。本データ転送システムは、前記ホスト装置が接続される第1入出力ポート(121)と、夫々の前記ターゲット装置が対応して接続されるn個の第2入出力ポート(123〜125)とを含み、前記第1入出力ポートと前記第2入出力ポートとの接続と前記第2入出力ポート間の接続が切り替え可能にされるスイッチングハブ(12)を更に有する。前記ターゲット装置は、データを一時的に格納するための記憶部(101)を含む。前記他のターゲット装置が、相互に通信を行うことにより、前記他のターゲット装置が保有する前記ホスト装置に転送するための転送データが1つの前記他のターゲット装置内の前記記憶部にまとめて格納される。前記ホスト装置と前記一のターゲット装置の通信が完了したら、前記転送データをまとめて格納したターゲット装置が、そのターゲット装置が保持する転送データと前記記憶部に格納された転送データとをまとめて前記ホスト装置に送信する。
[13] (Data transfer system)
A data transfer system (1) according to a typical embodiment of the present application includes a host device (11) and n (n is an integer of 3 or more) target devices (TGT_1 to TGT_3). The data transfer system includes a first input / output port (121) to which the host device is connected and n second input / output ports (123 to 125) to which the target devices are connected correspondingly. And a switching hub (12) that enables switching between the connection between the first input / output port and the second input / output port and the connection between the second input / output ports. The target device includes a storage unit (101) for temporarily storing data. When the other target devices communicate with each other, transfer data to be transferred to the host device held by the other target devices is collectively stored in the storage unit in one other target device. Is done. When the communication between the host device and the one target device is completed, the target device that collectively stores the transfer data collectively stores the transfer data held by the target device and the transfer data stored in the storage unit. Send to the host device.
これによれば、前記他のターゲット装置の夫々がホスト装置にデータを転送する場合に比べて、前記他のターゲット装置の全ての転送データの送信が完了するのに必要なトランザクション数が少なくなるので、転送におけるオーバーヘッドが小さくなり、スループットが向上する。これにより、データ転送システムにおけるUSB通信の通信時間を短縮することができる。 According to this, the number of transactions required to complete transmission of all transfer data of the other target device is reduced compared to the case where each of the other target devices transfers data to the host device. Transfer overhead is reduced and throughput is improved. Thereby, the communication time of USB communication in a data transfer system can be shortened.
2.実施の形態の詳細
実施の形態について更に詳述する。
2. Details of Embodiments Embodiments will be further described in detail.
≪実施の形態1≫
図1に、USB通信が可能なデータ転送システムが例示される。
<<
FIG. 1 illustrates a data transfer system capable of USB communication.
同図に示されるデータ転送システム1は、ホスト装置(HOST)11と、複数の周辺装置(ターゲット装置,PRD)TGT_1〜TGT_3と、スイッチングハブ(SW_HUB)12とを含んで構成され、ホスト装置11とターゲット装置TGT_1〜TGT_3(総称する場合は、単にTGTと表記する。)とは、スイッチングハブ12を介してUSB通信が可能にされる。
The
一般にUSB通信では、フレームという複数のパケットからなるデータブロックを所定の周期で転送することによって通信が行われる。前記所定の周期は、フル・スピードモードで1ms、ハイ・スピードモードでは125μsである。フレームは、SOF(Start of frame)と呼ばれるSOFパケットと、複数のトランザクションから構成される。トランザクションは、ホスト装置とターゲット装置との間で複数のパケットのやり取りすることによって実現される1つのデータ転送の最小単位である。トランザクションは、転送の種類及びターゲット装置のアドレスを指定するトークンパケットと、転送の対象のデータを含むデータパケットと、データの正常受信や受信ミス等を示すACKやNAC等のハンドシェイクパケットと、から構成される。例えば、バルク転送の場合、トークンパケットとして、ホスト装置からターゲット装置へのデータの転送を指示するOUTトークンと、ターゲット装置からホスト装置へのデータの転送を指示するINトークンがある。1フレーム内のトランザクションは、必要に応じてターゲット装置毎に割り当て可能にされ、これにより、1フレームの期間に各ターゲット装置に少しずつ転送時間を割り当てることができる。 In general, in USB communication, communication is performed by transferring a data block including a plurality of packets called a frame at a predetermined cycle. The predetermined period is 1 ms in the full speed mode and 125 μs in the high speed mode. The frame is composed of an SOF packet called SOF (Start of frame) and a plurality of transactions. A transaction is a minimum unit of one data transfer realized by exchanging a plurality of packets between a host device and a target device. The transaction consists of a token packet that specifies the type of transfer and the address of the target device, a data packet that contains the data to be transferred, and a handshake packet such as ACK or NAC that indicates normal reception or reception error of the data. Composed. For example, in the case of bulk transfer, there are an OUT token that instructs data transfer from the host device to the target device and an IN token that instructs data transfer from the target device to the host device as token packets. Transactions within one frame can be assigned to each target device as necessary, and transfer time can be assigned to each target device little by little during the period of one frame.
ホスト装置11は、スイッチングハブ12を介してターゲット装置TGT_1〜TGT_3の夫々とインターフェースされる。ホスト装置11は、例えば、パソコンやサーバ、家庭用のマルチメディア機器等である。ホスト装置11は、例えば、ロー・スピードモード(1.5Mbps)、フル・スピードモード(12Mbps)、及びハイ・スピードモード(480Mbps)に対応しており、何れかの通信スピードでターゲット装置TGT_1〜TGT_3にアクセス可能にされる。
The
ホスト装置11は、中央処理装置(CPU)110、メモリ(MRY)111、バス112、USBホストコントローラ(USB_CNT)113、及びその他の図示されない周辺回路を含んで構成される。特に制限されないが、中央処理装置110、メモリ111、バス112、USBホストコントローラ113、及びその他の図示されない周辺回路は、公知のCMOS集積回路の製造技術によって1個の単結晶シリコンのような半導体基板に形成される。ホスト装置11は、例えばマイクロコントローラである。
The
中央処理装置110は、メモリ111に予め格納されたプログラムにしたがって各種の演算処理を実行するとともに、ホスト装置11内の各機能部の統括的な制御を行う。メモリ111は、中央処理装置110による演算処理において演算結果やプログラム等が一時的に格納されるRAMや、中央処理装置110が実行するプログラム等を格納するROM等を含む。
The
USBホストコントローラ113は、ホスト装置11とターゲット装置TGT_1〜TGT_3との間のUSB通信を制御する。USBホストコントローラ113は、バス112を介して、中央処理装置110やメモリ111、図示されない周辺回路と共通に接続される。USBホストコントローラ113は、例えば、制御部(CNT)1130及び入出力ポート(I/O_PRT)1131を含む。入出力ポート1131は、スイッチングハブ12のアップストリームポート(入出力ポート121)に接続され、データの送受信が可能にされる。図示はしないが、入出力ポート1131は、例えば、複数の外部端子と、上記外部端子に供給されたデータを受信するとともに上記外部端子にデータを送信するための外部インターフェース回路と、を含んで構成される。
The
制御部1130は、入出力ポート1131を制御することにより、ターゲット装置TGT_1〜TGT_3との間のUSB通信を制御する。特に制限されないが、制御部1130は、中央処理装置がROMやRAMに格納されたプログラムを実行することにより各種の機能を実現するプログラム処理装置である。制御部1130は、ターゲット装置TGT_1〜TGT_3に対して通信要求の有無を順次問い合わせ(ポーリング)、通信要求の有ったターゲット装置との間で通信を確立する。このとき、スイッチングハブ12及びターゲット装置TGT_1〜TGT_3に対して、第1通信モードと第2通信モードの何れかを指定する。第1通信モードは、従来のUSB通信と同様に、ターゲット装置TGT_1〜TGT_3毎にホスト装置11とデータの送受信が可能にされるモードである。第2通信モードは、複数のターゲット装置TGTのデータをまとめてホスト装置11に送信可能なモードである。
The
具体的には、制御部1130は、一つのターゲット装置TGTとの通信において転送対象とされる転送データのデータ量を判別し、その通信時間が長くなると判断した場合には第2通信モードを指示し、そうでない場合には第1通信モードを指示する。例えば、ホスト装置11からターゲット装置TGT_3に対して転送データを送信するとき、制御部1130は、ターゲット装置TGT_3に送信すべき転送データのデータ量に基づいて、ターゲット装置TGT_3との通信が完了するまでの所要時間を算出し、所定の閾値と比較する。算出した所要時間が所定の閾値よりも小さい場合には、ターゲット装置TGT_3以外の他のターゲット装置TGT_1、TGT_2に対して第1通信モードでの通信を行うことを指示する。他方、算出した所要時間が所定の閾値よりも大きい場合には、ターゲット装置TGT_3以外の他のターゲット装置TGT_1、TGT_2に対して第2通信モードでの通信を行うことを指示するとともに、ホスト装置11と通信が可能になるまでの待機時間の情報を送信する。前記待機時間の情報は、例えば、ホスト装置11とターゲット装置TGT_3との通信で予定されている予測トランザクション数の情報や、ホスト装置11とターゲット装置TGT_3との通信に要する予測時間の情報等である。
Specifically, the
スイッチングハブ12は、ホスト装置11と接続可能なアップストリームポートとしての入出力ポート(I/O_PRT)121と、ターゲット装置TGTと接続可能なダウンストリームポートとしてのn個(nは3以上の整数)の入出力ポート(I/O_PRT)と、スイッチング回路(SWCIR)122、制御部(CNT)120と、を含んで構成される。なお、同図には、ダウンストリームポートとしてのn個の入出力ポートとして、入出力ポート123、124、125の3つのポートが例示されているが、3つ以上であれば、その数に制限はない。
The switching hub 12 includes an input / output port (I / O_PRT) 121 as an upstream port connectable to the
入出力ポート121は、上述したように、ホスト装置11における入出力ポート1131と接続され、データの送受信が可能にされる。入出力ポート123〜125は、対応するターゲット装置TGT_1〜TGT_3の入出力ポート(I/O_PRT)104に接続され、データの送受信が可能にされる。図示はしないが、入出力ポート121、123〜125は、例えば、複数の外部端子と、上記外部端子に供給されたデータを受信するとともに上記外部端子にデータを送信するための外部インターフェース回路と、を含んで構成される。スイッチング回路122は、入出力ポート121と入出力ポート123〜125の間の接続と遮断を切り替えるとともに、入出力ポート123〜125間の接続と遮断を切り替える。これにより、入出力ポート121、123〜125間で様々な通信経路を確立することができる。特に限定されないが、図1には、入出力ポート123と入出力ポート124とを接続し、入出力ポート121と入出力ポート125とを接続した場合が例示されている。
As described above, the input /
制御部120は、入出力ポート121、123〜125及びスイッチング回路122を制御することにより、入出力ポート121に接続されたホスト装置11と入出力ポート123〜125に接続されたターゲット装置TGT_1〜TGT_3との間の通信を制御する。例えば、制御部120は、ホスト装置11におけるUSBホストコントローラ113から送信された制御信号に基づいてスイッチング回路122を制御することにより、指定された通信経路を確立し、ホスト装置11とターゲット装置TGT_1〜TGT_3通信や、ターゲット装置TGT_1〜TGT_3同士の通信を可能にする。
The
ターゲット装置TGT_1〜TGT_3は、ホスト装置11との間のUSB通信に加え、ターゲット装置間でのUSB通信が可能にされる。ターゲット装置TGTは、例えば、OTG(On−The−Go)規格に対応したUSB機器であり、ハードディスクドライブやメモリカードリーダ、プリンタ、デジタルカメラ等である。
The target devices TGT_1 to TGT_3 are enabled to perform USB communication between target devices in addition to USB communication with the
ターゲット装置TGT_1〜TGT_3は、例えば、USBターゲットコントローラ100及び内部回路103を含んで構成される。内部回路103は、ターゲット装置TGT_1〜TGT_3特有の機能を実現するための機能部である。USBターゲットコントローラ100は、スイッチングハブ12を介して、ホスト装置11や他のターゲット装置と通信を行う。USBターゲットコントローラ100は、例えば、バッファメモリ101、制御部102、及び入出力ポート(I/O_PRT)104を含んで構成される。USBターゲットコントローラ100は、特に制限されないが、公知のCMOS集積回路の製造技術によって1個の単結晶シリコンのような半導体基板に形成された1チップの半導体集積回路である。なお、バッファメモリ101は、制御部102等と同じチップに構成しても良いし、別チップとしても良く、特に制限されない。入出力ポート104は、スイッチングハブ12における入出力ポート123〜125の何れか1つと接続され、データの送受信が可能にされる。図示はしないが、入出力ポート104は、例えば、複数の外部端子と、上記外部端子に供給されたデータを受信するとともに上記外部端子にデータを送信するための外部インターフェース回路と、を含んで構成される。バッファメモリ101は、データを格納するための記憶装置である。例えば、バッファメモリ101は大容量の揮発性の記憶領域を含んで構成される。特に制限されないが、バッファメモリ101はRAMである。
The target devices TGT_1 to TGT_3 include, for example, a
制御部102は、スイッチングハブ12を介してホスト装置11から供給された制御信号に基づいて入出力ポート104を制御することにより、スイッチングハブ12を介したホスト装置11との通信、及び他のターゲット装置との通信を可能にする。例えば、ホスト装置11から供給された制御信号によって第1通信モードが指示された場合には、制御部102は、内部回路103から供給されたホスト装置11に送信すべき転送データを入出力ポート104から送信するとともに、入出力ポート104で受信した転送データを必要に応じて内部回路103に供給する。他方、ホスト装置11から供給された制御信号によって第2通信モードが指示された場合には、制御部102は、他のターゲット装置との間で通信を行う。具体的には、制御部102は、他のターゲット装置との間で、バッファメモリ101の記憶容量の大きさを示す記憶容量の情報を相互にやり取りし、自らのバッファメモリ101の記憶容量が最も大きいか否かを判別する。最も大きいと判別した場合には、データの蓄積が可能であることを示す情報を他のターゲット装置に送信するとともに、他のターゲット装置から送信された転送データをバッファメモリ101に格納する。そして、自らの内部回路103から供給された転送データと、バッファメモリ101に格納された転送データとをまとめて、ホスト装置11に送信する。他方、自らのバッファメモリ101の記憶容量が他のターゲット装置のそれよりも小さいと判別した場合には、制御部102は、ホスト装置11に送信すべき転送データを、最も記憶容量の大きいバッファメモリ101を持つターゲット装置に対して送信する。より具体的には、制御部102は、ホスト装置11から受信した前記待機時間の情報に基づいて、他のターゲット装置との間で通信可能な時間を算出するとともに、その算出した時間内に送信可能な最大データ量を算出する。そして、算出した最大データ量に応じた転送データを最も記憶容量の大きいバッファメモリ101を持つターゲット装置に対して送信する。なお、上記算出した最大データ量よりも、送信先のターゲット装置のバッファメモリの記憶容量の方が小さい場合には、当該バッファメモリに格納可能なデータ量の転送データを送信する。そして、ホスト装置とターゲット装置の通信を終わった段階で、残りの転送データをホスト装置にあらためて送信するようにすれば良い。
The
次に、データ転送システム1における第2通信モードでの通信方法について、図2、3を用いて詳細に説明する。
Next, a communication method in the second communication mode in the
図2は、実施の形態1に係るデータ転送システムにおける第2通信モードによる通信方法の一例を示すフロー図である。同図には、ホスト装置11がターゲット装置TGT_3に対して大容量のデータを送信し、ターゲット装置TGT_1及びターゲット装置TGT_2が小容量のデータをホスト装置11に送信する場合の通信手順が例示されている。
FIG. 2 is a flowchart showing an example of a communication method in the second communication mode in the data transfer system according to the first embodiment. The figure illustrates a communication procedure when the
先ず、ホスト装置11は、ターゲット装置TGT_3に送信すべき転送データのデータ量に基づいて、ターゲット装置TGT_3との通信が完了するまでの所要時間を算出し、所定の閾値と比較する。ホスト装置11は、算出した所要時間が所定の閾値よりも大きい判断したら、バルク通信のトランザクションによってターゲット装置TGT_1に対して第2通信モードでの通信を行うことを指示するとともに、ホスト装置11と通信が可能になるまでの待機時間の情報を送信する(S101)。ターゲット装置TGT_1は、それに対する応答(ACK)をホスト装置11に送信する(S102)。同様に、ホスト装置11は、ターゲット装置TGT_2に対して第2通信モードでの通信を行うことを指示するとともに、前記待機時間の情報を送信する(S103)。ターゲット装置TGT_2は、それに対する応答(ACK)をホスト装置11に送信する(S104)。ホスト装置11はターゲット装置TGT_3との間で通信を開始する(S105)。具体的には、ホスト装置11は、他のターゲット装置TGT_1,TGT_2に通知した前記待機時間の情報に基づく送信完了予定時刻まで、転送データを送信することを繰り返し行う。仮にデータの再送が必要となり、当初の送信完了予定時刻までに全てのデータの送信が終わらない場合であっても、当初の送信完了予定時刻になったらデータの送信を停止する。このとき、ホスト装置11は、ターゲット装置TGT_1、TGT_2のトランザクションを発行せず、ターゲット装置TGT_3のトランザクションのみによってデータの送信を行う。これにより、より短い時間でターゲット装置TGT_3へのデータ転送を完了することができる。
First, the
処理S105においてホスト装置11とターゲット装置TGT_3の通信が開始されると、ターゲット装置TGT_1、TGT_2間の通信が開始される。具体的には、ホスト装置11からターゲット装置TGT_1,TGT_2への定期的なSOFパケットの送信が停止したら、それをトリガとして、ターゲット装置TGT_1及びTGT_2は通信を開始する。先ず、ターゲット装置TGT_1は、自らが保有するバッファメモリ101に関する記憶容量の情報をターゲット装置TGT_2に送信する(S106)。次に、ターゲット装置TGT_2が、自らが保有するバッファメモリ101に関する記憶容量の情報をターゲット装置TGT_1に送信する(S107)。特に制限されないが、ターゲット装置TGT_1、TGT_2のどちらから記憶容量の情報の送信を開始するかは、例えば、ホスト装置11と接続されたときに割り振られたターゲット装置毎のアドレス番号の小さい方から行うものとする。記憶容量の情報を受信したターゲット装置TGT_1、TGT_2は、どちらのバッファメモリ101の記憶容量が大きいかを判別する。ターゲット装置TGT_1のバッファメモリ101の方が記憶容量が大きいと判断された場合、ターゲット装置TGT_1が、ターゲット装置TGT_2に対して、データの蓄積が可能であることを通知する(S108)。上記通知を受け取ったターゲット装置TGT_2は、それに対する応答(ACK)をターゲット装置TGT_1に送信する(S109)。
When communication between the
その後、ターゲット装置TGT_2は、ホスト装置11に転送すべき転送データをターゲット装置TGT_1に送信することを開始する(S110)。具体的には、ターゲット装置TGT_2は、処理S103において受信した前記待機時間の情報に基づいて、ターゲット装置TGT_1との間で通信可能な時間を算出するとともに、その算出した時間内に送信可能な最大データ量を算出する。そして、算出した最大データ量に応じた転送データをターゲット装置TGT_1に対して送信する。一方、ターゲット装置TGT_1は、ターゲット装置TGT_2から送信された転送データを自らのバッファメモリ101に逐次格納する。
Thereafter, the target device TGT_2 starts transmitting transfer data to be transferred to the
ホスト装置11は、ターゲット装置TGT_3に対するデータの送信が完了したら、その送信が完了したことをターゲット装置TGT_1に通知する(S111)。ターゲット装置TGT_1は、それに対する応答(ACK)に加え、ターゲット装置TGT_2の転送データを蓄積していることをホスト装置11に通知する(S112)。同様に、ホスト装置11は、送信が完了したことをターゲット装置TGT_2に通知する(S113)。ターゲット装置TGT_2は、それに対する応答(ACK)をホスト装置11に通知する(S114)。その後、ターゲット装置TGT_1は、バッファメモリ101に格納したターゲット装置TGT_2の転送データと、自らが保有するホスト装置11に転送すべき転送データとをまとめて、ホスト装置11に送信する(S115)。例えば、ターゲット装置TGT_1は、最初のバルク通知のトランザクションでデータの蓄積を行ったことをホスト装置11に通知し、その後のトランザクションでまとめて転送データを送信する。この通信は、ホスト装置11とターゲット装置TGT_1との間でのみで行われる。すなわち、この通信のフレームには、ターゲット装置TGT_2やターゲット装置TGT_3のトランザクションは含まれず、ターゲット装置TGT_1のトランザクションのみよってデータが送信される。
When the transmission of data to the target device TGT_3 is completed, the
ターゲット装置TGT_1は、ホスト装置11へのデータ送信が完了したら、バッファメモリ101に格納した転送データをホスト装置11に転送したことを、ターゲット装置TGT_2に対して通知する(S116)。ターゲット装置TGT_2は、それに対する応答(ACK)をターゲット装置TGT_1に通知する(S117)。以上の処理が完了すると、ホスト装置11及びターゲット装置TGTは、通常のオペレーションに戻る。
When the data transmission to the
図3は、第2通信モードによる通信方法の別の一例を示すフロー図である。同図には、ターゲット装置TGT_3がホスト装置11に対して大容量のデータを送信し、ターゲット装置TGT_1及びターゲット装置TGT_2が小容量のデータをホスト装置11に送信する場合の通信手順が例示されている。
FIG. 3 is a flowchart showing another example of the communication method in the second communication mode. The figure illustrates a communication procedure when the target device TGT_3 transmits a large amount of data to the
先ず、ターゲット装置TGT_3は、ホスト装置11からのポーリングによりデータ転送の有無の問い合わせを受けたら、転送データの優先的な送信要求と、送信の目的とされる転送データのデータ量の情報をホスト装置11に通知する(S201)。ホスト装置11は、それに対する応答をターゲット装置TGT_3に送信する(S202)。ホスト装置11は、受信した前記データ量の情報に基づいて、ターゲット装置TGT_3との通信が完了するまでの所要時間を算出し、所定の閾値と比較する。ホスト装置11は、算出した所要時間が所定の閾値よりも大きい判断したら、バルク通信のトランザクションによってターゲット装置TGT_1に対して第2通信モードでの通信を行うことを指示するとともに、ホスト装置11と通信が可能になるまでの待機時間の情報を送信する(S101)。ターゲット装置TGT_1は、それに対する応答(ACK)をホスト装置11に送信する(S102)。同様に、ホスト装置11は、ターゲット装置TGT_2に対して第2通信モードでの通信を行うことを指示するとともに、ホスト装置11と通信が可能になるまでの待機時間の情報を送信する(S103)。ターゲット装置TGT_2は、それに対する応答(ACK)をホスト装置11に送信する(S104)。
First, when the target device TGT_3 receives an inquiry about the presence / absence of data transfer from the
ホスト装置11は、ターゲット装置TGT_3との間で通信を開始する(S205)。具体的には、ホスト装置11は、他のターゲット装置TGT_1,TGT_2に通知した前記待機時間の情報に基づく送信完了予定時刻まで、転送データを受信することを繰り返し行う。仮にデータの再送が必要となり、当初の送信完了予定時刻までに全てのデータの受信が終わらない場合であっても、当初の送信完了予定時刻になったらデータの受信を停止する。このとき、ホスト装置11は、ターゲット装置TGT_1、TGT_2のトランザクションを発行せず、ターゲット装置TGT_3のトランザクションのみによってデータの送信を行う。
The
処理S205においてホスト装置11とターゲット装置TGT_3の通信が開始されると、ターゲット装置TGT_1、TGT_2間の通信が開始される。その後の処理は、図2の処理S106〜S117と同様である。これにより、ターゲット装置TGT_2の転送データがターゲット装置TGT_1のバッファメモリ101に一旦蓄積され、ホスト装置11とターゲット装置TGT_3との通信の完了後に、ターゲット装置TGT_1が、自らの転送データとバッファメモリ101に蓄積されたデータとをまとめてホスト装置11に送信する。
When communication between the
以上の通信方法によれば、1つのフレームの中で割り振られたトランザクションによって夫々のターゲット装置がホスト装置にデータを転送する場合に比べて、データ転送におけるオーバーヘッドを小さくすることができる。例えば、上記例の場合、ターゲット装置TGT_1が転送データをまとめてホスト装置11に送信することにより、ターゲット装置TGT_1とターゲット装置TGT_2とが別個にホスト装置11にデータを送信する場合に比べてイン・トークンパケットの送信回数が少なくなるため、データ転送におけるオーバーヘッドが小さくなり、スループットが向上する。
According to the above communication method, the overhead in data transfer can be reduced as compared with the case where each target device transfers data to the host device by a transaction allocated in one frame. For example, in the case of the above example, when the target device TGT_1 collectively transmits the transfer data to the
また、USB規格では、スイッチングハブに接続されたターゲット装置の通信スピードが相異する場合、通信スピードが一番遅いターゲット装置の通信スピードに従わなくてはならないが、上記方法によれば、転送データをバッファメモリに蓄積したターゲット装置が取り得る最速の通信スピードでデータ通信を行うことができる。例えば、ターゲット装置TGT_2がロー・スピードモードに、ターゲット装置TGT_1がフル・スピードモードに対応している場合、1フレーム内でターゲット装置TGT_1とターゲット装置TGT_2がデータ送信を行うには、ターゲット装置TGT_2だけでなくターゲット装置TGT_1もロー・スピードモードで通信を行う必要がある。しかしながら、上記方法によれば、ターゲット装置TGT_1のみホスト装置11と通信を行うので、フル・スピードモードでデータを転送することができ、スループットを向上させることができる。
Further, in the USB standard, when the communication speed of the target device connected to the switching hub is different, the communication speed of the target device having the slowest communication speed must be followed. The data communication can be performed at the fastest communication speed that can be taken by the target device that stores the data in the buffer memory. For example, when the target device TGT_2 is compatible with the low speed mode and the target device TGT_1 is compatible with the full speed mode, the target device TGT_1 and the target device TGT_2 can perform data transmission within one frame only by the target device TGT_2. In addition, the target device TGT_1 needs to communicate in the low speed mode. However, according to the above method, since only the target device TGT_1 communicates with the
以上、実施の形態1に係るデータ転送システム1によれば、USB通信の通信時間を短縮することが可能となる。
As described above, according to the
≪実施の形態2≫
実施の形態1では、一つのターゲット装置がホスト装置と通信を行っている期間に他のターゲット装置間で通信を行い、他のターゲット装置の1つに転送データを蓄積する構成及び方法を例示したが、実施の形態2では、上記期間に、他のターゲット装置の転送データをスイッチングハブに蓄積する構成及び方法を例示する。
<<
In the first embodiment, the configuration and method of performing communication between other target devices while one target device is communicating with the host device and accumulating transfer data in one of the other target devices are exemplified. However, the second embodiment exemplifies a configuration and method for storing transfer data of other target devices in the switching hub during the period.
図4に、実施の形態2に係る、USB通信が可能なデータ転送システムを例示する。 FIG. 4 illustrates a data transfer system capable of USB communication according to the second embodiment.
同図に示されるデータ転送システム2は、ホスト装置11と、複数の周辺装置(ターゲット装置)TGT_1〜TGT_3と、スイッチングハブ22とを含んで構成され、ホスト装置11とターゲット装置TGTとは、スイッチングハブ22を介してUSB通信が可能にされる。なお、同図において、実施の形態1に係るデータ転送システムと同様の構成要素には同一の符号を付して、その詳細な説明を省略する。
The
スイッチングハブ22は、ホスト装置11のUSBホストコントローラ113と接続可能にされるアップストリームポートとしての入出力ポート121と、ターゲット装置TGTと接続可能にされるダウンストリームポートとしてのn個(nは3以上の整数)の入出力ポートと、スイッチング回路122、制御部220と、バッファメモリ(BUF)225と、を含んで構成される。なお、同図には、ダウンストリームポートとしてのn個の入出力ポートとして、入出力ポート123、124、125の3つのポートが例示されているが、3つ以上であれば、その数に制限はない。特に制限されないが、入出力ポート121、123、124、125、スイッチング回路122、制御部220、及びバッファメモリ225は、公知のCMOS集積回路の製造技術によって1個の単結晶シリコンのような半導体基板に形成される。なお、バッファメモリ225は、制御部220等と同じチップに構成しても良いし、別チップとしても良く、特に制限されない。
The switching
バッファメモリ225は、データを格納するための記憶装置である。例えば、バッファメモリ225は大容量の揮発性の記憶領域を含んで構成される。特に制限されないが、バッファメモリ225は、RAMである。
The
制御部220は、入出力ポート121、123〜125及びスイッチング回路122を制御することにより、入出力ポート121に接続されたホスト装置11と入出力ポート123〜125に接続されたターゲット装置TGT_1A〜TGT_3Aとの間の通信を制御する。例えば、制御部220は、ホスト装置11におけるUSBホストコントローラ113から送信された制御信号によって第1通信モードが指示された場合には、指定されたターゲット装置TGTが接続される入出力ポート123〜125と入出力ポート121との接続を確立することにより、ホスト装置11と指定されたターゲット装置TGTとの通信を可能にする。他方、USBホストコントローラ113から送信された制御信号によって第2通信モードが指示された場合には、制御部220は、第1通信モードと同様に一つのターゲット装置とホスト装置11との通信経路を確立するとともに、擬似ホスト装置として、他のターゲット装置とスイッチングハブ22との間のデータの送受信を可能にする。具体的には、制御部220は、第2通信モードを指示する制御信号を受け取ったら、データの蓄積が可能であることを他のターゲット装置に通知するとともに、通知したターゲット装置から送信された夫々の転送データをバッファメモリ225にまとめて格納する。そして、バッファメモリ225に格納された転送データを、ホスト装置11にまとめて送信する。なお、バッファメモリ225の記憶容量よりも他のターゲット装置から送信される転送データの方が大きい場合には、当該バッファメモリに格納可能なデータ量の転送データだけを受信する。そして、ホスト装置とターゲット装置の通信を終わった段階で、第1通信モードにおいて、残りの転送データを持つターゲット装置からホスト装置11にあらためて、前記残りの転送データを送信するようにすれば良い。
The
ターゲット装置TGT_1A〜TGT_3Aは、ホスト装置11との間のUSB通信に加え、スイッチングハブとの間でUSB通信が可能にされる。ターゲット装置TGT_1A〜TGT_3Aは、例えば、USBターゲットコントローラ200及び内部回路103を含んで構成される。USBターゲットコントローラ200は、スイッチングハブ22を介してホスト装置11と通信を行うとともに、擬似ホスト装置としてのスイッチングハブ22と通信を行う。USBターゲットコントローラ200は、例えば、制御部202、及び入出力ポート(I/O_PRT)104を含んで構成される。
The target devices TGT_1A to TGT_3A are enabled to perform USB communication with the switching hub in addition to USB communication with the
制御部202は、ホスト装置11から供給された制御信号によって第1通信モードが指示された場合には、内部回路103から供給されたホスト装置11に送信すべき転送データを入出力ポート104から送信するとともに、入出力ポート104で受信した転送データを内部回路103に供給する。他方、ホスト装置11から供給された制御信号によって第2通信モードが指示された場合には、制御部202は、擬似ホスト装置としてのスイッチングハブ22と通信を行う。例えば、制御部202は、ホスト装置11から受信した前記待機時間の情報に基づいて、スイッチングハブ22との間で通信可能な時間を算出するとともに、その算出した時間内に送信可能な最大データ量を算出する。そして、スイッチングハブ22からデータの蓄積が可能であることの通知を受け取ったら、算出した最大データ量に応じた転送データをスイッチングハブ22に対して送信する。
When the first communication mode is instructed by the control signal supplied from the
次に、データ転送システム2における第2通信モードでの通信方法について、図5、6を用いて詳細に説明する。
Next, a communication method in the second communication mode in the
図5は、データ転送システム2における第2通信モードによる通信方法の一例を示すフロー図である。同図には、ホスト装置11がターゲット装置TGT_3Aに対して大容量のデータを送信し、ターゲット装置TGT_1A及びターゲット装置TGT_2Aが小容量のデータをホスト装置11に送信する場合の通信手順が例示されている。
FIG. 5 is a flowchart showing an example of a communication method in the second communication mode in the
先ず、ホスト装置11は、ターゲット装置TGT_3Aに送信すべき転送データのデータ量に基づいて、ターゲット装置TGT_3Aとの通信が完了するまでの所要時間を算出し、所定の閾値と比較する。ホスト装置11は、算出した所要時間が所定の閾値よりも大きい判断したら、バルク通信のトランザクションによって、スイッチングハブ22に対して第2通信モードでの通信を行うことを指示するとともに、ホスト装置11との通信が可能になるまでの待機時間の情報を送信する(S301)。スイッチングハブ22(制御部220)は、それに対する応答(ACK)をホスト装置11に送信する(S302)。同様に、ホスト装置11は、ターゲット装置TGT_1Aに対して第2通信モードでの通信を行うことを指示するとともに、前記待機時間の情報を送信する(S303)。ターゲット装置TGT_1Aは、それに対する応答(ACK)をホスト装置11に送信する(S304)。更に、ホスト装置11は、ターゲット装置TGT_2Aに対して第2通信モードでの通信を行うことを指示するとともに、前記待機時間の情報を送信する(S305)。ターゲット装置TGT_2Aは、それに対する応答(ACK)をホスト装置11に送信する(S306)。
First, the
ホスト装置11はターゲット装置TGT_3Aとの間で通信を開始する(S307)。具体的には、ホスト装置11は、スイッチングハブ22や他のターゲット装置TGT_1A,TGT_2Aに通知した前記待機時間の情報に基づく送信完了予定時刻になるまで、転送データを送信することを繰り返し行う。仮にデータの再送が必要となり、当初の送信完了予定時刻までに全てのデータの送信が終わらない場合であっても、当初の送信完了予定時刻になったら転送データの送信を停止する。このとき、ホスト装置11は、ターゲット装置TGT_1A、TGT_2Aのトランザクションを発行せず、ターゲット装置TGT_3Aのトランザクションのみによってデータの送信を行う。
The
処理S307においてホスト装置11とターゲット装置TGT_3Aの通信が開始されると、スイッチングハブ22とターゲット装置TGT_1A、TGT_2Aの通信が開始される。具体的には、ホスト装置11からターゲット装置TGT_1A,TGT_2Aへの定期的なSOFパケットの送信が停止したら、それをトリガとして、スイッチングハブ22が擬似ホスト装置として、ターゲット装置TGT_1A、TGT_2Aと通信を開始する。先ず、スイッチングハブ22は、データの蓄積が可能であることをターゲット装置TGT_1Aに送信する(S308)。ターゲット装置TGT_1Aは、それに対する応答(ACK)をスイッチングハブ22に送信する(S309)。同様に、スイッチングハブ22は、データの蓄積が可能であることをターゲット装置TGT_2Aに送信する(S310)。ターゲット装置TGT_2Aは、それに対する応答(ACK)をスイッチングハブ22に送信する(S311)。
When the communication between the
その後、ターゲット装置TGT_1Aは、ホスト装置11に転送すべき転送データをスイッチングハブ22に送信する(S312)。具体的には、ターゲット装置TGT_1Aは、処理S303において受信した前記待機時間の情報に基づいて、スイッチングハブ22との間で通信可能な時間を算出するとともに、その算出した時間内に送信可能な最大データ量を算出する。そして、算出した最大データ量に応じた転送データをスイッチングハブ22に対して送信する。一方、スイッチングハブ22は、ターゲット装置TGT_1Aから送信された転送データをバッファメモリ225に逐次格納する。同様に、ターゲット装置TGT_2Aは、ホスト装置11に転送すべき転送データをスイッチングハブ22に送信する(S313)。具体的には、ターゲット装置TGT_2は、処理S305において受信した前記待機時間の情報に基づいて、スイッチングハブ22との間で通信可能な時間を算出するとともに、その算出した時間内に送信可能な最大データ量を算出する。そして、算出した最大データ量に応じた転送データをスイッチングハブ22に対して送信する。一方、スイッチングハブ22は、ターゲット装置TGT_2Aから送信された転送データをバッファメモリ225に逐次格納する。
Thereafter, the target device TGT_1A transmits the transfer data to be transferred to the
ホスト装置11は、ターゲット装置TGT_3Aに対するデータの送信が完了したら、その送信が完了したことをスイッチングハブ22に通知する(S314)。スイッチングハブ22は、それに対する応答(ACK)に加え、ターゲット装置TGT_1A、TGT_2Aの転送データを蓄積していることをホスト装置11に通知する(S315)。同様に、ホスト装置11は、送信が完了したことをターゲット装置TGT_1Aに通知する(S316)。ターゲット装置TGT_1Aは、それに対する応答(ACK)をホスト装置11に通知する(S317)。更に、ホスト装置11は、送信が完了したことをターゲット装置TGT_2Aに通知する(S318)。ターゲット装置TGT_2Aは、それに対する応答(ACK)をホスト装置11に通知する(S319)。
When the transmission of data to the target device TGT_3A is completed, the
その後、スイッチングハブ22は、バッファメモリ225に格納したターゲット装置TGT_1A及びターゲット装置TGT_2Aの転送データをホスト装置11に送信する(S320)。例えば、スイッチングハブ22は、最初のバルク通知のトランザクションでデータの蓄積を行ったことをホスト装置11に通知し、その後のトランザクションでまとめて転送データを送信する。この通信は、ホスト装置11とスイッチングハブ22との間でのみで行われる。すなわち、この通信のフレームには、ターゲット装置TGT_3Aのトランザクションや、ターゲット装置TGT_1A、TGT_2Aのトランザクションが含まれず、スイッチングハブ22のトランザクションのみよってデータが送信される。
Thereafter, the switching
スイッチングハブ22は、ホスト装置11へのデータ送信が完了したら、バッファメモリ225に格納した転送データをホスト装置11に転送したことをターゲット装置TGT_1Aに対して通知する(S321)。ターゲット装置TGT_1Aは、それに対する応答(ACK)をスイッチングハブ22に通知する(S322)。同様に、スイッチングハブ22は、バッファメモリ225に格納した転送データをホスト装置11に転送したことをターゲット装置TGT_2Aに対して通知する(S323)。ターゲット装置TGT_2Aは、それに対する応答(ACK)をスイッチングハブ22に通知する(S324)。以上の処理が完了すると、ホスト装置11及びターゲット装置TGTは、通常のオペレーションに戻る。
When the data transmission to the
図6は、データ転送システム2における第2通信モードによる通信方法の別の一例を示すフロー図である。同図には、ターゲット装置TGT_3Aがホスト装置11に対して大容量のデータを送信し、ターゲット装置TGT_1A及びターゲット装置TGT_2Aが小容量のデータをホスト装置11に送信する場合の通信手順が例示されている。
FIG. 6 is a flowchart showing another example of the communication method in the second communication mode in the
先ず、ターゲット装置TGT_3Aは、ホスト装置11からのポーリングによりデータ転送の有無の問い合わせを受けたら、転送データの優先的な送信要求と、送信の目的とされる転送データのデータ量の情報をホスト装置11に通知する(S401)。ホスト装置11は、それに対する応答をターゲット装置TGT_3Aに送信する(S402)。ホスト装置11は、ターゲット装置TGT_3Aから受信した前記データ量の情報に基づいて、ターゲット装置TGT_3Aとの通信が完了するまでの所要時間を算出し、所定の閾値と比較する。ホスト装置11は、算出した所要時間が所定の閾値よりも大きい判断したら、スイッチングハブ22に対して第2通信モードでの通信を行うことを指示するとともに、ホスト装置11との通信が可能になるまでの待機時間の情報を送信する(S301)。スイッチングハブ22(制御部220)は、それに対する応答(ACK)をホスト装置11に送信する(S302)。同様に、ホスト装置11は、ターゲット装置TGT_1Aに対して第2通信モードでの通信を行うことを指示するとともに、前記待機時間の情報を送信する(S303)。ターゲット装置TGT_1Aは、それに対する応答(ACK)をホスト装置11に送信する(S304)。更に、ホスト装置11は、ターゲット装置TGT_2Aに対して第2通信モードでの通信を行うことを指示するとともに、前記待機時間の情報を送信する(S305)。ターゲット装置TGT_2Aは、それに対する応答(ACK)をホスト装置11に送信する(S306)。
First, when the target device TGT_3A receives an inquiry about the presence / absence of data transfer from the
ホスト装置11はターゲット装置TGT_3Aとの間で通信を開始する(S407)。具体的には、ホスト装置11は、スイッチングハブ22や他のターゲット装置TGT_1A,TGT_2Aに通知した待機時間の情報に基づく送信完了予定時刻まで、転送データの受信を繰り返し行う。仮にデータの再送が必要となり、当初の送信完了予定時刻までに全てのデータの受信が終わらない場合であっても、当初の送信完了予定時刻になったらデータの受信を停止する。このとき、ホスト装置11は、ターゲット装置TGT_1A、TGT_2Aのトランザクションを発行せず、ターゲット装置TGT_3Aのトランザクションのみによってデータの送信を行う。処理S407においてホスト装置11とターゲット装置TGT_3の通信が開始されると、スイッチングハブ22とターゲット装置TGT_1A、TGT_2Aとの間の通信が開始される。その後の処理は、図5の処理S308〜S324と同様である。これにより、ターゲット装置TGT_1A、TGT_2Aの転送データがスイッチングハブ22のバッファメモリ225に一旦蓄積され、ホスト装置11とターゲット装置TGT_3Aとの通信の完了後に、スイッチングハブ22が、バッファメモリ225に蓄積された転送データをまとめてホスト装置11に送信する。
The
以上の通信方法によれば、1つのフレームの中で割り振られたトランザクションによって、夫々のターゲット装置がホスト装置にデータを転送する場合に比べて、データ転送におけるオーバーヘッドを小さくすることができる。例えば、上記例の場合、スイッチングハブ22が転送データをまとめてホスト装置11に送信することにより、ターゲット装置TGT_1Aとターゲット装置TGT_2Aとが別個にホスト装置11にデータを送信する場合に比べてイン・トークンパケットの送信回数が少なくなるため、データ転送におけるオーバーヘッドが小さくなり、スループットが向上する。
According to the above communication method, the overhead in data transfer can be reduced as compared with the case where each target device transfers data to the host device by a transaction allocated in one frame. For example, in the case of the above example, the switching
また、スイッチングハブ22が取り得る最速の通信スピードでデータ通信を行うことができる。例えば、ターゲット装置TGT_1Aとターゲット装置TGT_2Aがロー・スピードモードに、スイッチングハブ22がフル・スピードモードに対応している場合、1フレーム内でターゲット装置TGT_1A、TGT_2Aがデータ送信を行うには、ターゲット装置TGT_1、TGT_2とホスト装置11との間ではロー・スピードモードで通信を行う必要がある。しかしながら、上記方法によれば、スイッチングハブ22のみがデータを送信するので、フル・スピードモードでホスト装置11と通信を行うことができ、スループットを向上させることができる。
Further, data communication can be performed at the fastest communication speed that the switching
以上、実施の形態2に係るデータ転送システム2によれば、USB通信の通信時間を短縮することが可能となる。
As described above, according to the
≪実施の形態3≫
図7に、実施の形態1に係る通信方法を適用したデータ転送システムの具体例を示す。同図に示されるデータ転送システム1Aにおいて、ホスト装置11としてのメディアサーバ(MD_SVR)11Aは、スイッチングハブ12Aを介して、ターゲット装置TGTとしてのビデオカメラ(VDCAM)10A、スマートフォン(SMTPH)10B、及びデジタルカメラ(DGCAM)10Cと、USBによりインターフェースされる。
<<
FIG. 7 shows a specific example of a data transfer system to which the communication method according to
メディアサーバ11Aは、動画データや画像データ等が蓄積可能とされ、必要に応じてモニタ(TV等)に接続されて映像の再生が可能にされる。ビデオカメラ10Aは、録画した大容量の動画データが格納される。スマートフォン10Bは、例えばカメラ機能を備え、小量の画像データが蓄積されている。また、スマートフォン10B内のUSBターゲットコントローラ100は、一次的にデータの蓄積が可能なバッファメモリ101を有している。デジタルカメラ10Cは、小量の画像データが蓄積されている。
The
データ転送システム1Aにおいて、ビデオカメラ10A、スマートフォン10B、及びデジタルカメラ10Cからメディアサーバ11Aにデータを転送する場合を考える。この場合、ビデオカメラ10Aの転送データが他のスマートフォン10Bやデジタルカメラ10Cの転送データよりもデータ量が大きいため、先ず、メディアサーバ11Aとビデオカメラ10Aとの間で優先的にUSB通信を行う。通信を開始する際、メディアサーバ11Aは、スマートフォン10B及びデジタルカメラ10Cに対して、第2通信モードで通信するように指示するとともに前記待機時間の情報を送信する。メディアサーバ11Aとビデオカメラ10Aが通信を行っている期間に、スマートフォン10B及びデジタルカメラ10Cは相互に通信を行う。この通信において、デジタルカメラ10Cは、メディアサーバ11Aに転送すべき画像データとしての転送データをスマートフォン10Bに送信し、当該転送データがスマートフォン10Bのバッファメモリ101に蓄積される。その後、メディアサーバ11Aとビデオカメラ10Aの通信が完了すると、スマートフォン10Bはメディアサーバ11Aとの間でUSB通信を確立し、自らが保有する画像データと、バッファメモリ101に蓄積されたデジタルカメラ10Cの画像データとをまとめて送信する。これにより、従来のUSB通信に比べて各ターゲット装置からホスト装置へのデータ転送を効率良く行うことができ、データ転送システムにおけるUSB通信の通信時間を短縮することができる。
Consider a case in which data is transferred from the
≪実施の形態4≫
図8に、実施の形態1に係る通信方法を適用したデータ転送システムの別の具体例を示す。同図に示されるデータ転送システム1Bにおいて、ホスト装置11としてのメディアサーバ11Aは、スイッチングハブ12Aを介して、ターゲット装置TGTとしてのスマートフォン(SMTPH)10D、スマートフォン10B、及びデジタルカメラ10Cと、USBによりインターフェースされる。なお、図8において実施の形態3に係るデータ転送システム1Aと同様の構成要素には同一の符号を付して、その詳細な説明を省略する。
<< Embodiment 4 >>
FIG. 8 shows another specific example of the data transfer system to which the communication method according to the first embodiment is applied. In the
スマートフォン10Dは、大容量のデータの格納が可能にされる不揮発性の記憶装置(例えばフラッシュメモリ)を備え、例えば、当該記憶装置に格納した動画データの再生が外出先で可能にされる。 The smartphone 10D includes a nonvolatile storage device (for example, a flash memory) that can store a large amount of data. For example, the moving image data stored in the storage device can be reproduced on the go.
データ転送システム1Bにおいて、メディアサーバ11Aからスマートフォン10Dに動画データを転送するとともに、スマートフォン10B及びデジタルカメラ10Cからメディアサーバ11Aにデータを転送する場合を考える。この場合、メディアサーバ11Aからスマートフォン10Dに転送される転送データ(動画データ)が、他のスマートフォン10Bやデジタルカメラ10Cの転送データよりもデータ量が大きいため、先ず、メディアサーバ11Aとスマートフォン10Dとの間で優先的にUSB通信を行う。通信を開始する際、メディアサーバ11Aは、スマートフォン10B及びデジタルカメラ10Cに対して、第2通信モードで通信するように指示するとともに前記待機時間の情報を送信する。メディアサーバ11Aとスマートフォン10Dとが通信を行っている期間に、スマートフォン10B及びデジタルカメラ10Cは相互に通信を行う。この通信において、デジタルカメラ10Cは、メディアサーバ11Aに転送すべき画像データとしての転送データをスマートフォン10Bに送信し、当該転送データがスマートフォン10Bのバッファメモリ101に蓄積される。その後、メディアサーバ11Aとスマートフォン10Dの通信が完了すると、スマートフォン10Bはメディアサーバ11Aとの間でUSB通信を確立し、自らが保有する画像データと、バッファメモリ101に蓄積されたデジタルカメラ10Cの画像データとをまとめて送信する。これにより、実施の形態3に係るデータ転送システムと同様に、データ転送システムにおけるUSB通信の通信時間を短縮することができる。
In the
以上本発明者によってなされた発明を実施形態に基づいて具体的に説明したが、本発明はそれに限定されるものではなく、その要旨を逸脱しない範囲において種々変更可能であることは言うまでもない。 Although the invention made by the present inventor has been specifically described based on the embodiments, it is needless to say that the present invention is not limited thereto and can be variously modified without departing from the gist thereof.
例えば、実施の形態1において各ターゲット装置TGTがUSBターゲットコントローラ100内にバッファメモリ101を備える構成を例示したが、これに限られない。例えば、ホスト装置11とターゲット装置TGT_3が通信を行っている期間に、ターゲット装置TGT_1,TGT_2が通信を行う場合、ターゲット装置TGT_1、TGT_2の少なくとも1つがバッファメモリを備えていればよい。
For example, in the first embodiment, the configuration in which each target device TGT includes the
また、実施の形態1乃至4では、ターゲット装置TGTが3つの場合を例示したが、これに限られず、3つ以上であれば、上記通信方法によるUSB通信の通信時間の短縮の効果が得られる。例えば、実施の形態1において、ターゲット装置が4つスイッチングハブ12に接続されていたとすると、一つのターゲット装置がホスト装置と通信を行っている間、残りの3つのターゲット装置間で通信を行うことができる。このとき、上記3つのターゲット装置は、相互に記憶容量の情報をやり取りし、夫々のターゲット装置が自らのバッファメモリの記憶容量が最も大きいか否かを判別する。そして、最も大きい記憶容量のバッファメモリを有すると判断したターゲット装置が残り2つのターゲット装置に対して、データの蓄積が可能であることを示す情報を通知する。それ以降の処理を実施の形態1で示した方法と同様することで、上記と同様の効果を得ることができる。 In the first to fourth embodiments, the case where the number of target devices TGT is three has been exemplified. However, the number of target devices TGT is not limited to this, and the number of the target devices TGT is three or more. . For example, in the first embodiment, if four target devices are connected to the switching hub 12, communication is performed between the remaining three target devices while one target device is communicating with the host device. Can do. At this time, the three target devices exchange storage capacity information with each other, and determine whether each target device has the largest storage capacity in its buffer memory. Then, the target device determined to have the buffer memory with the largest storage capacity notifies the remaining two target devices of information indicating that data can be accumulated. By performing the subsequent processing in the same manner as the method described in the first embodiment, the same effect as described above can be obtained.
実施の形態2の図5,6において、ターゲット装置TGT_1A,TGT_2Aからホスト装置11に転送データを送信する場合について例示したが、ホスト装置11からターゲット装置TGT_1A,TGT_2Bに転送データを送信する場合でも同様に、USB通信の通信時間を短縮することができる。例えば、初めに、ホスト装置11からスイッチングハブ22に対して、ターゲット装置TGT_1A,TGT_2Aに転送すべき転送データをまとめて送信し、バッファメモリ225に格納しておく。そして、ホスト装置11とターゲット装置TGT_3Aが通信を開始したら、スイッチングハブ22がバッファメモリ225に格納された転送データをターゲット装置TGT_1、TGT2に順次転送すれば良い。
In FIGS. 5 and 6 of the second embodiment, the case where the transfer data is transmitted from the target devices TGT_1A and TGT_2A to the
バッファメモリ101、225が揮発性の記憶装置である場合を例示したが、書き換え可能な不揮発性の記憶装置(例えばフラッシュメモリ)であっても良い。
Although the case where the
1 データ転送システム
11 ホスト装置
TGT,TGT_1〜TGT_3 周辺装置(ターゲット装置,PRD)
12 スイッチングハブ
110 中央処理装置(CPU)
111 メモリ(MRY)
112 バス
113 USBホストコントローラ(USB_CNT)
1130 制御部(CNT)
1131 入出力ポート(I/O_PRT)
120 制御部(CNT)
121 入出力ポート(I/O_PRT,アップストリームポート)
122 スイッチング回路(SWCIR)
123,124,125 入出力ポート(I/O_PRT,ダウンストリームポート)
100 USBターゲットコントローラ
101 バッファメモリ
102 制御部
103 内部回路
104 入出力ポート(I/O_PRT)
2 データ転送システム
TGT_1A,TGT_2A、TGT_3A
22 スイッチングハブ
220 制御部(CNT)
225 バッファメモリ(BUF)
200 USBターゲットコントローラ
202 制御部(CNT)
1A、2A データ転送システム
11A メディアサーバ
12A スイッチングハブ
10A ビデオカメラ
10B、10D スマートフォン
10C デジタルカメラ
1
12
111 memory (MRY)
112
1130 Control unit (CNT)
1131 I / O port (I / O_PRT)
120 Control unit (CNT)
121 I / O port (I / O_PRT, upstream port)
122 Switching circuit (SWCIR)
123, 124, 125 I / O ports (I / O_PRT, downstream ports)
100
2 Data transfer system TGT_1A, TGT_2A, TGT_3A
22
225 Buffer memory (BUF)
200
1A, 2A
Claims (12)
前記ホスト装置と前記n個のターゲット装置とは、前記ターゲット装置毎に前記ホスト装置とデータの送受信が可能な第1通信モードと、複数のターゲット装置のデータをまとめてホスト装置に送信可能な第2通信モードとを切り替えて通信可能とされ、
前記ホスト装置が、一のターゲット装置と通信を行うとき、前記一のターゲット装置以外の他のターゲット装置に対して通信モードを指示する第1処理と、
前記ホスト装置が、前記一のターゲット装置と通信を開始する第2処理と、
前記第1処理において前記第2通信モードが指示された場合に、前記他のターゲット装置が、相互に通信を行うことにより、夫々が保有する前記ホスト装置に転送するための転送データを1つの前記他のターゲット装置内の前記記憶部にまとめて格納する第3処理と、
前記ホスト装置と前記一のターゲット装置の通信の完了後、前記第3処理において前記転送データを前記記憶部にまとめて格納したターゲット装置が、自らの転送データと前記記憶部に格納した転送データとをまとめて前記ホスト装置に送信する第4処理と、を含む通信方法。 A host device and n (n is an integer of 3 or more) target devices having a storage unit for temporarily storing data for transmitting and receiving data according to the USB standard via a switching hub A communication method,
The host device and the n target devices are a first communication mode capable of transmitting and receiving data to and from the host device for each target device, and a first communication mode in which data of a plurality of target devices can be collectively transmitted to the host device. It is possible to communicate by switching between 2 communication modes,
When the host device communicates with one target device, a first process for instructing a communication mode to a target device other than the one target device;
A second process in which the host device starts communication with the one target device;
When the second communication mode is instructed in the first process, the other target devices communicate with each other, thereby transferring one transfer data to be transferred to the host device held by each of the other target devices. A third process for storing together in the storage unit in another target device;
After the communication between the host device and the one target device is completed, the target device that collectively stores the transfer data in the storage unit in the third process stores its transfer data and the transfer data stored in the storage unit. 4th process which transmits to a said host apparatus collectively.
前記他のターゲット装置が、夫々の保有する前記記憶部の記憶容量の大きさを示す記憶容量の情報を相互に送受信する第5処理と、
前記他のターゲット装置が、前記記憶容量の情報に基づいて自らの前記記憶部の記憶容量が最も大きいか否かを判別し、前記記憶容量が最も大きいと判断したターゲット装置が、それ以外のターゲット装置に対して、転送データの蓄積が可能であることを通知する第6処理と、
前記それ以外のターゲット装置が、前記ホスト装置に転送するための転送データを前記記憶容量が最も大きいと判断したターゲット装置に送信し、前記記憶容量が最も大きいと判断したターゲット装置が、受信した前記転送データを前記記憶部に格納する第7処理と、を含む請求項2に記載の通信方法。 The third process includes
A fifth process in which the other target devices mutually transmit / receive information on storage capacity indicating the storage capacity of the storage unit held by each other, and
The other target device determines whether or not its storage unit has the largest storage capacity based on the storage capacity information, and the target device that has determined that the storage capacity is the largest is the other target. A sixth process for notifying the apparatus that transfer data can be stored;
The other target device transmits the transfer data to be transferred to the host device to the target device that has been determined to have the largest storage capacity, and the target device that has been determined to have the largest storage capacity has received the received The communication method according to claim 2, further comprising: a seventh process of storing transfer data in the storage unit.
前記第7処理において、前記それ以外のターゲット装置は、前記待機時間を示す情報に基づいて、前記ホスト装置と前記一のターゲット装置の通信が完了するまでに送信可能なデータ量を算出するとともに、前記算出したデータ量に応じた前記転送データを、前記記憶容量が最も大きいと判断したターゲット装置に対して送信するデータとする請求項3に記載の通信方法。 In the first process, the host device further transmits to the other target device information indicating a waiting time until communication with the host device becomes possible,
In the seventh process, the other target devices calculate the amount of data that can be transmitted before the communication between the host device and the one target device is completed based on the information indicating the standby time, The communication method according to claim 3, wherein the transfer data corresponding to the calculated data amount is data to be transmitted to a target device determined to have the largest storage capacity.
前記ホスト装置と前記n個のターゲット装置とは、前記ターゲット装置毎に前記ホスト装置とデータの送受信が可能な第1通信モードと、複数のターゲット装置のデータをまとめてホスト装置に送信可能な第2通信モードとを切り替えて通信可能とされ、
前記スイッチングハブは、一次的にデータの格納が可能な記憶部を含み、
前記ホスト装置が、一のターゲット装置と通信を行うとき、前記一のターゲット装置以外の他のターゲット装置と前記スイッチングハブに対して通信モードを指示する第1処理と、
前記ホスト装置が、前記一のターゲット装置と通信を開始する第2処理と、
前記第1処理において前記第2通信モードが指示された場合に、前記他のターゲット装置が、前記スイッチングハブと通信を行うことにより、夫々の前記他のターゲット装置が保有する前記ホスト装置に転送するための転送データを前記スイッチングハブ内の前記記憶部にまとめて格納する第3処理と、
前記ホスト装置と前記一のターゲット装置の通信の完了後、前記スイッチングハブが前記記憶部に格納した前記転送データをまとめて前記ホスト装置に送信する第4処理と、を含む通信方法。 A communication method for transmitting and receiving data in accordance with the USB standard between a host device and n (n is an integer of 3 or more) target devices via a switching hub,
The host device and the n target devices are a first communication mode capable of transmitting and receiving data to and from the host device for each target device, and a first communication mode in which data of a plurality of target devices can be collectively transmitted to the host device. It is possible to communicate by switching between 2 communication modes,
The switching hub includes a storage unit capable of temporarily storing data;
When the host device communicates with one target device, a first process of instructing a communication mode to another target device other than the one target device and the switching hub;
A second process in which the host device starts communication with the one target device;
When the second communication mode is instructed in the first process, the other target device communicates with the switching hub and transfers to the host device held by each of the other target devices. A third process for collectively storing transfer data for storage in the storage unit in the switching hub;
And a fourth process in which the switching hub collectively transmits the transfer data stored in the storage unit to the host device after communication between the host device and the one target device is completed.
前記スイッチングハブが、前記転送データの蓄積が可能であることを前記他のターゲット装置に通知する第5処理と、
前記他のターゲット装置が、前記転送データを前記スイッチングハブに送信し、前記スイッチングハブが受信した前記転送データを前記記憶部に蓄積する第6処理と、を含む請求項2に記載の通信方法。 The third process includes
A fifth process in which the switching hub notifies the other target device that the transfer data can be stored;
The communication method according to claim 2, further comprising: a sixth process in which the other target device transmits the transfer data to the switching hub and accumulates the transfer data received by the switching hub in the storage unit.
前記第6処理において、前記他のターゲット装置は、前記待機時間を示す情報に基づいて、前記ホスト装置と前記一のターゲット装置の通信が完了するまでに送信可能なデータ量を算出するとともに、前記算出したデータ量に応じた前記転送データを、前記スイッチングハブに送信するデータとする請求項9に記載の通信方法。 In the first process, the host device further transmits to the other target device and the switching hub information indicating a waiting time until communication with the host device becomes possible,
In the sixth process, the other target device calculates the amount of data that can be transmitted before the communication between the host device and the one target device is completed based on the information indicating the standby time. The communication method according to claim 9, wherein the transfer data corresponding to the calculated data amount is data to be transmitted to the switching hub.
ホスト装置と接続するための第1入出力ポートと、
ターゲット装置と接続するためのn個(nは3以上の整数)の第2入出力ポートと、
前記第1入出力ポートと前記第2入出力ポートとの間の接続を切り替えることにより、前記第1入出力ポートに接続された前記ホスト装置と前記第2入出力ポートに接続された前記ターゲット装置との間の通信を制御するための通信制御部と、
記憶部と、を有し、
前記通信制御部は、前記第1入出力ポートと一の前記第2入出力ポートとの接続を確立しているとき、前記ホスト装置に転送するための転送データが他の前記第2入出力ポートに供給された場合には、前記転送データを前記記憶部にまとめて格納し、前記第1入出力ポートと前記一の前記第2入出力ポートとの接続の解除後に、前記記憶部に格納した転送データをまとめて前記第1入出力ポートから出力することが可能にされるスイッチングハブ。 A switching hub capable of communication according to the USB standard,
A first input / output port for connecting to a host device;
N second input / output ports (n is an integer of 3 or more) for connecting to the target device;
The host device connected to the first input / output port and the target device connected to the second input / output port by switching the connection between the first input / output port and the second input / output port A communication control unit for controlling communication with
A storage unit;
When the communication control unit establishes a connection between the first input / output port and one second input / output port, transfer data to be transferred to the host device is transferred to the other second input / output port. The transfer data is stored together in the storage unit and stored in the storage unit after the connection between the first input / output port and the one second input / output port is released. A switching hub capable of collectively outputting transfer data from the first input / output port.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2013039045A JP2014168144A (en) | 2013-02-28 | 2013-02-28 | Communication method and switching hub |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2013039045A JP2014168144A (en) | 2013-02-28 | 2013-02-28 | Communication method and switching hub |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2014168144A true JP2014168144A (en) | 2014-09-11 |
Family
ID=51617634
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2013039045A Pending JP2014168144A (en) | 2013-02-28 | 2013-02-28 | Communication method and switching hub |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2014168144A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2015076731A (en) * | 2013-10-09 | 2015-04-20 | Necエンジニアリング株式会社 | Usb repeater, usb repeating method, and usb repeating program |
CN117578740A (en) * | 2024-01-15 | 2024-02-20 | 泉州市鑫盛电气设备有限公司 | Digital intelligent electricity management system and method |
-
2013
- 2013-02-28 JP JP2013039045A patent/JP2014168144A/en active Pending
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2015076731A (en) * | 2013-10-09 | 2015-04-20 | Necエンジニアリング株式会社 | Usb repeater, usb repeating method, and usb repeating program |
CN117578740A (en) * | 2024-01-15 | 2024-02-20 | 泉州市鑫盛电气设备有限公司 | Digital intelligent electricity management system and method |
CN117578740B (en) * | 2024-01-15 | 2024-05-31 | 泉州市鑫盛电气设备有限公司 | Digital intelligent electricity management system and method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9710410B2 (en) | Camera control slave devices with multiple slave device identifiers | |
US8042743B2 (en) | IC card comprising a main device and an additional device | |
WO2009147811A1 (en) | Interface unit, communications system, non-volatile storage unit, communication mode switching method and integrated circuit | |
JP2015019373A5 (en) | ||
JP5902702B2 (en) | Initiator device, target device, communication system, timeout detection method, and timeout detection program | |
JP2006024217A (en) | Method for sharing single host controller with multiple functional devices | |
US8745296B2 (en) | Serial storage protocol compatible frame conversion, at least in part being compatible with SATA and one packet being compatible with PCIe protocol | |
US20050174877A1 (en) | Bus arrangement and method thereof | |
WO2014092551A1 (en) | System and method for optimal memory management between cpu and fpga unit | |
JP2014168144A (en) | Communication method and switching hub | |
US9742623B2 (en) | Master device, communication system, and communication method | |
JP6176058B2 (en) | Direct memory access control device, control method thereof, and information processing system | |
JP2007293708A (en) | Wireless usb device | |
JP2004328262A (en) | Usb hub device, usb peripheral device, and data transmission and reception method | |
US20150281370A1 (en) | Apparatus, communication control system, and communication control method | |
JP2012039266A (en) | Communication control device and method | |
US20140347986A1 (en) | Wireless communication device, wireless communication method, and wireless communication control program | |
EP3229145A1 (en) | Parallel processing apparatus and communication control method | |
US11734206B2 (en) | Information processing device | |
KR20100077708A (en) | Method and apparatus for transmitting of data between master and slave | |
JP2020191520A (en) | Imaging device and control method thereof | |
WO2019015049A1 (en) | Method and device for exception handling in wireless sensor network | |
WO2022124083A1 (en) | Communication device, communication method, and program | |
JP3842790B2 (en) | Wireless transmission device | |
JP5652866B2 (en) | Bus arbitration circuit and bus arbitration method |