JP2017123117A - Communication device, communication system, communication method, and program - Google Patents

Communication device, communication system, communication method, and program Download PDF

Info

Publication number
JP2017123117A
JP2017123117A JP2016002844A JP2016002844A JP2017123117A JP 2017123117 A JP2017123117 A JP 2017123117A JP 2016002844 A JP2016002844 A JP 2016002844A JP 2016002844 A JP2016002844 A JP 2016002844A JP 2017123117 A JP2017123117 A JP 2017123117A
Authority
JP
Japan
Prior art keywords
communication
host
under test
host device
function unit
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
Application number
JP2016002844A
Other languages
Japanese (ja)
Inventor
斉藤 隆
Takashi Saito
隆 斉藤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
KDDI Corp
Original Assignee
KDDI Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by KDDI Corp filed Critical KDDI Corp
Priority to JP2016002844A priority Critical patent/JP2017123117A/en
Publication of JP2017123117A publication Critical patent/JP2017123117A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Bus Control (AREA)
  • Information Transfer Systems (AREA)

Abstract

PROBLEM TO BE SOLVED: To make it possible to connect a device with a plurality of host devices simultaneously.SOLUTION: A communication device 1 includes: a first device function unit 11 for communicating with a testing host device 2; a second device function unit 12 for communicating with an external host device 3; a host function unit 13 for communicating with a testing device 4; and a communication controller 16 for transmitting first down data that the first device function unit 11 receives from the testing host device 2 and second down data that the second device function unit 12 receives from the external host device 3 to the testing device 4 via the host function unit 13.SELECTED DRAWING: Figure 2

Description

本発明は、データを送受信する通信装置、通信システム、通信方法及びプログラムに関する。   The present invention relates to a communication device, a communication system, a communication method, and a program for transmitting and receiving data.

電子機器間でデータを送受信するためのインターフェイスとして、USB(Universal Serial Bus)が普及している。USBの規格においては、コンピュータ等のホスト装置と、プリンタやメモリ等のデバイス装置とが規定されており、ホスト装置とデバイス装置との間でデータが送受信される。近年、USBの普及に伴い、複数のホスト装置を1台のデバイス装置に接続したいというニーズが高まっている。特許文献1においては、複数のホスト装置を接続するためのインターフェイスを有するデバイス装置が開示されている。   USB (Universal Serial Bus) is widely used as an interface for transmitting and receiving data between electronic devices. In the USB standard, a host device such as a computer and a device device such as a printer and a memory are defined, and data is transmitted and received between the host device and the device device. In recent years, with the widespread use of USB, there is an increasing need to connect a plurality of host devices to a single device device. In Patent Document 1, a device device having an interface for connecting a plurality of host devices is disclosed.

特開2009−217334号公報JP 2009-217334 A

特許文献1に記載された従来のデバイス装置を用いることで、1台のデバイス装置を複数のホスト装置に接続することが実現できる。しかしながら、従来のデバイス装置においては、接続する複数のホスト装置を切り替える必要があり、デバイス装置を複数のホスト装置と同時に接続することが困難であった。   By using the conventional device device described in Patent Document 1, it is possible to connect one device device to a plurality of host devices. However, in the conventional device device, it is necessary to switch a plurality of host devices to be connected, and it is difficult to connect the device device simultaneously with the plurality of host devices.

そこで、本発明はこの点に鑑みてなされたものであり、デバイス装置を複数のホスト装置と同時に接続することを可能にするための通信装置、通信システム、通信方法及びプログラムを提供することを目的とする。   Therefore, the present invention has been made in view of this point, and an object thereof is to provide a communication device, a communication system, a communication method, and a program for enabling a device device to be simultaneously connected to a plurality of host devices. And

本発明の第1の態様においては、第1ホスト装置と通信する第1デバイス機能部と、第2ホスト装置と通信する第2デバイス機能部と、デバイス装置と通信するホスト機能部と、前記第1デバイス機能部が前記第1ホスト装置から受信した第1下りデータ、及び前記第2デバイス機能部が前記第2ホスト装置から受信した第2下りデータを、前記ホスト機能部を介して前記デバイス装置に送信する通信制御部と、を有する通信装置を提供する。   In the first aspect of the present invention, a first device function unit that communicates with a first host device, a second device function unit that communicates with a second host device, a host function unit that communicates with a device device, First device data received by one device function unit from the first host device and second downlink data received by the second device function unit from the second host device via the host function unit And a communication control unit for transmitting to the communication device.

前記ホスト機能部は、例えば、前記デバイス装置から受信した上りデータを受信し、前記通信制御部は、前記ホスト機能部が受信した前記上りデータのうち、第1の上りデータを、前記第1デバイス機能部を介して前記第1ホスト装置に送信し、かつ第2の上りデータを、前記第2デバイス機能部を介して前記第2ホスト装置に送信する。   The host function unit receives, for example, uplink data received from the device device, and the communication control unit receives first uplink data among the uplink data received by the host function unit as the first device. The second uplink data is transmitted to the first host device via the function device, and the second uplink data is transmitted to the second host device via the second device function device.

前記通信制御部は、前記第1デバイス機能部を介して受信した前記第1下りデータを、一以上の第1通信パイプを用いて前記デバイス装置に送信し、前記第2デバイス機能部から受信した前記第2下りデータを、一以上の第2通信パイプを用いて前記デバイス装置に送信してもよい。   The communication control unit transmits the first downlink data received via the first device function unit to the device apparatus using one or more first communication pipes and receives the first downlink data from the second device function unit. The second downlink data may be transmitted to the device device using one or more second communication pipes.

上記の通信装置は、前記第1ホスト装置と前記デバイス装置との間で送受信される第1データの送受信に用いられる前記一以上の第1通信パイプの識別情報を、前記第1ホスト装置及び前記デバイス装置に関連付けて記憶し、前記第2ホスト装置と前記デバイス装置との間で送受信される第2データの送受信に用いられる前記一以上の第2通信パイプの識別情報を、前記第2ホスト装置及び前記デバイス装置に関連付けて記憶する記憶部をさらに有してもよい。   The above communication device uses the identification information of the one or more first communication pipes used for transmission / reception of the first data transmitted / received between the first host device and the device device as the first host device and the device The second host device stores identification information of the one or more second communication pipes stored in association with a device device and used for transmission / reception of second data transmitted / received between the second host device and the device device. And a storage unit that stores the information in association with the device device.

前記デバイス装置は、少なくとも第1アプリケーション及び第2アプリケーションを実行し、前記記憶部は、前記第1ホスト装置及び前記第1アプリケーションに関連付けて前記一以上の第1通信パイプの識別情報を記憶し、前記第2ホスト装置及び前記第2アプリケーションに関連付けて前記一以上の第2通信パイプの識別情報を記憶してもよい。   The device device executes at least a first application and a second application, and the storage unit stores identification information of the one or more first communication pipes in association with the first host device and the first application, The identification information of the one or more second communication pipes may be stored in association with the second host device and the second application.

前記通信制御部は、前記第1ホスト装置との通信に用いられる前記一以上の第1通信パイプの識別情報及び前記第2ホスト装置との通信に用いられる前記一以上の第2通信パイプの識別情報を、前記デバイス装置に通知してもよい。   The communication control unit includes identification information of the one or more first communication pipes used for communication with the first host device and identification of the one or more second communication pipes used for communication with the second host device. Information may be notified to the device apparatus.

前記通信制御部は、前記第1ホスト装置と前記デバイス装置とが前記一以上の第1通信パイプで通信中に前記第2ホスト装置からの通信要求を受けたことに応じて、前記デバイス装置に対して前記一以上の第2通信パイプの識別情報を通知してもよい。   The communication control unit receives the communication request from the second host device during communication between the first host device and the device device via the one or more first communication pipes. Alternatively, the identification information of the one or more second communication pipes may be notified.

上記の通信装置は、前記第1ホスト装置から受信した前記第1下りデータの前記デバイス装置への送信を停止させる停止指示を受け付ける受付部をさらに有し、前記通信制御部は、前記受付部が前記停止指示を受け付けると、前記一以上の第1通信パイプを用いて前記第1ホスト装置から受信した前記第1下りデータの前記デバイス装置への送信を停止してもよい。前記通信制御部は、前記一以上の第1通信パイプを介して前記第1ホスト装置から受信した前記第1下りデータを、前記一以上の第2通信パイプを介して前記第2ホスト装置に転送してもよい。   The communication device further includes a reception unit that receives a stop instruction to stop transmission of the first downlink data received from the first host device to the device device, and the communication control unit includes: When the stop instruction is received, transmission of the first downlink data received from the first host device to the device device using the one or more first communication pipes may be stopped. The communication control unit transfers the first downlink data received from the first host device via the one or more first communication pipes to the second host device via the one or more second communication pipes. May be.

また、前記通信制御部は、前記一以上の第2通信パイプを介して前記第2ホスト装置から受信した前記第2下りデータを、前記一以上の第1通信パイプを介して前記デバイス装置に送信してもよい。   The communication control unit transmits the second downlink data received from the second host device via the one or more second communication pipes to the device device via the one or more first communication pipes. May be.

本発明の第2の態様においては、ホスト機能を有するコンピュータと、前記コンピュータと通信する通信装置と、を備える通信システムであって、前記通信装置は、ホスト装置と通信する第1デバイス機能部と、前記コンピュータと通信する第2デバイス機能部と、デバイス装置と通信するホスト機能部と、前記第1デバイス機能部が前記ホスト装置から受信した第1下りデータ、及び前記第2デバイス機能部が前記コンピュータから受信した第2下りデータを、前記ホスト機能部を介して前記デバイス装置に送信する通信制御部と、を有する通信システムを提供する。   In a second aspect of the present invention, there is provided a communication system comprising a computer having a host function and a communication device that communicates with the computer, wherein the communication device includes a first device function unit that communicates with the host device; A second device function unit that communicates with the computer; a host function unit that communicates with a device device; the first downlink data received by the first device function unit from the host device; and the second device function unit There is provided a communication system including a communication control unit that transmits second downlink data received from a computer to the device device via the host function unit.

本発明の第3の態様においては、第1ホスト装置、第2ホスト装置及びデバイス装置と接続される通信装置が実行する通信方法であって、前記第1ホスト装置から第1下りデータを受信するステップと、前記第2ホスト装置から第2下りデータを受信するステップと、前記第1ホスト装置から受信した第1下りデータ、及び前記第2ホスト装置から受信した第2下りデータを前記デバイス装置に送信するステップと、を有する通信方法を提供する。   According to a third aspect of the present invention, there is provided a communication method executed by a communication device connected to the first host device, the second host device, and the device device, wherein the first downlink data is received from the first host device. Receiving the second downlink data from the second host device, the first downlink data received from the first host device, and the second downlink data received from the second host device to the device device And a step of transmitting.

本発明の第4の態様においては、第1ホスト装置、第2ホスト装置及びデバイス装置と接続される通信装置が有するコンピュータが実行するプログラムであって、前記第1ホスト装置から第1下りデータを受信するステップと、前記第2ホスト装置から第2下りデータを受信するステップと、前記第1ホスト装置から受信した第1下りデータ、及び前記第2ホスト装置から受信した第2下りデータを前記デバイス装置に送信するステップと、を有するプログラムを提供する。   According to a fourth aspect of the present invention, there is provided a program executed by a computer included in a communication device connected to the first host device, the second host device, and the device device, wherein the first downlink data is received from the first host device. Receiving the second downlink data from the second host device; receiving the first downlink data received from the first host device; and the second downlink data received from the second host device as the device. And a step of transmitting to the apparatus.

本発明によれば、デバイス装置を複数のホスト装置と同時に接続することが可能になるという効果を奏する。   According to the present invention, it is possible to simultaneously connect a device device to a plurality of host devices.

第1の実施形態に係る通信システムの構成を示す図である。It is a figure which shows the structure of the communication system which concerns on 1st Embodiment. 通信装置の構成を示す図である。It is a figure which shows the structure of a communication apparatus. ルーティングテーブルの一例を示す図である。It is a figure which shows an example of a routing table. アプリケーションと通信パイプとの関係を示す模式図である。It is a schematic diagram which shows the relationship between an application and a communication pipe. 割り込み動作について説明するための模式図である。It is a schematic diagram for demonstrating interruption operation | movement. 割り込み動作が発生する場合のシーケンス図である。FIG. 11 is a sequence diagram when an interrupt operation occurs. データ吸収・転送モードの動作について説明するための模式図である。It is a schematic diagram for demonstrating operation | movement of data absorption and transfer mode. データ吸収・転送モードにおけるシーケンス図である。It is a sequence diagram in a data absorption / transfer mode. データ挿入モードについて説明するための模式図である。It is a schematic diagram for demonstrating data insertion mode. データ挿入モードにおけるシーケンス図である。It is a sequence diagram in data insertion mode.

<第1の実施形態>
[通信システムSの概要]
図1は、第1の実施形態に係る通信システムSの構成を示す図である。通信システムSは、通信装置1と、被試験ホスト装置2と、外部ホスト装置3と、被試験デバイス装置4と、上位制御装置5とを有する。被試験ホスト装置2及び外部ホスト装置3は、USBのホスト装置であり、被試験デバイス装置4は、USBのデバイス装置である。ホスト装置は、デバイス装置との間でデータ通信を行う際にデバイス装置を制御する。デバイス装置は、ホスト装置からの制御に基づいて、ホスト装置との間でデータ通信を行う。
<First Embodiment>
[Outline of Communication System S]
FIG. 1 is a diagram illustrating a configuration of a communication system S according to the first embodiment. The communication system S includes a communication device 1, a host device under test 2, an external host device 3, a device device under test 4, and a host control device 5. The host device under test 2 and the external host device 3 are USB host devices, and the device under test 4 is a USB device device. The host device controls the device device when performing data communication with the device device. The device device performs data communication with the host device based on control from the host device.

本実施形態においては、被試験ホスト装置2、外部ホスト装置3及び被試験デバイス装置4がUSBインターフェイスを有する装置である場合について説明するが、被試験ホスト装置2、外部ホスト装置3及び被試験デバイス装置4は、USBインターフェイスを有する装置に限らない。被試験ホスト装置2及び外部ホスト装置3が、データ通信時に被試験デバイス装置4を制御する機能を有し、被試験デバイス装置4が、被試験ホスト装置2又は外部ホスト装置3の制御に基づいてデータ通信を行う機能を有する限りにおいて、被試験ホスト装置2、外部ホスト装置3及び被試験デバイス装置4は、USBインターフェイス以外の他のインターフェイスを介してデータ通信を行う装置であってもよい。   In this embodiment, the case where the host device under test 2, the external host device 3, and the device under test device 4 are devices having a USB interface will be described. However, the host device under test 2, the external host device 3, and the device under test are described. The device 4 is not limited to a device having a USB interface. The host device under test 2 and the external host device 3 have a function of controlling the device under test 4 during data communication, and the device under test 4 is based on the control of the host device under test 2 or the external host device 3. As long as it has a function of performing data communication, the host device under test 2, the external host device 3, and the device under test device 4 may be devices that perform data communication via an interface other than the USB interface.

通信装置1は、被試験ホスト装置2及び外部ホスト装置3、並びに被試験デバイス装置4と接続されている。通信装置1は、被試験デバイス装置4を被試験ホスト装置2及び外部ホスト装置3と同時に接続して、被試験デバイス装置4と被試験ホスト装置2との間でデータ通信を行っている間に、被試験デバイス装置4と外部ホスト装置3との間でデータ通信を行うことができるようにする。通信装置1は、USBホスト側のインターフェイス機能及びUSBデバイス側のインターフェイス機能をエミュレーションするので、USBエミュレータとも称される。通信装置1の詳細については後述する。   The communication device 1 is connected to the host device under test 2, the external host device 3, and the device under test 4. The communication apparatus 1 connects the device under test 4 simultaneously with the host device under test 2 and the external host device 3 and performs data communication between the device under test 4 and the host device under test 2. Data communication can be performed between the device under test 4 and the external host device 3. The communication device 1 is also called a USB emulator because it emulates the interface function on the USB host side and the interface function on the USB device side. Details of the communication device 1 will be described later.

被試験ホスト装置2は、USBホスト装置側のインターフェイスを有しており、USBデバイス装置側のインターフェイスを有する被試験デバイス装置4との間でデータを送受信することができる。被試験ホスト装置2又は被試験デバイス装置4の調査や試験を行う必要がある場合に、図1に示すように、被試験ホスト装置2と被試験デバイス装置4との間に通信装置1が接続され、被試験ホスト装置2及び被試験デバイス装置4は、通信装置1を介してデータを送受信する。被試験ホスト装置2は、電力スマートメータ、自動販売機、車輛運行管理装置(デジタルタコメータ)、遠隔監視制御装置、監視カメラ又は非常通報装置等であり、被試験ホスト装置2が出力可能なデータを、被試験デバイス装置4及び携帯電話網を介して、データ収集センター等に設けられたサーバ等の外部装置に送信する。   The host device under test 2 has an interface on the USB host device side, and can send and receive data to and from the device under test device 4 having an interface on the USB device device side. When it is necessary to investigate or test the host device under test 2 or the device under test 4, the communication device 1 is connected between the host device under test 2 and the device under test 4 as shown in FIG. The host device under test 2 and the device under test device 4 transmit and receive data via the communication device 1. The host device under test 2 is a power smart meter, vending machine, vehicle operation management device (digital tachometer), remote monitoring and control device, monitoring camera, emergency call device, or the like. Then, the data is transmitted to an external device such as a server provided in a data collection center or the like via the device under test 4 and the mobile phone network.

外部ホスト装置3は、被試験ホスト装置2と同様にUSBホスト装置側のインターフェイスを有しており、通信装置1を介して被試験デバイス装置4との間でデータを送受信することができる。外部ホスト装置3は、例えば、被試験ホスト装置2と被試験デバイス装置4との間のデータ通信状況が正常であるかどうかを確認するために用いられる装置であり、被試験ホスト装置2及び被試験デバイス装置4の内部ログデータを取得することができる。   The external host device 3 has an interface on the USB host device side like the host device under test 2, and can send and receive data to and from the device under test device 4 via the communication device 1. The external host device 3 is, for example, a device used to check whether the data communication status between the host device under test 2 and the device under test 4 is normal. The internal log data of the test device device 4 can be acquired.

被試験デバイス装置4は、USBデバイス装置側のインターフェイスを有している。被試験デバイス装置4は、例えば、被試験ホスト装置2から受信したデータを携帯電話網に送信し、携帯電話網を介して受信したデータを被試験ホスト装置2に送信するための通信モジュールである。被試験デバイス装置4は、少なくとも、被試験ホスト装置2と通信する際に実行される第1アプリケーション、及び外部ホスト装置3と通信する際に実行される第2アプリケーションを実行することができる。   The device under test 4 has an interface on the USB device device side. The device under test 4 is a communication module for transmitting, for example, data received from the host under test 2 to the mobile phone network and transmitting data received via the mobile phone network to the host under test 2. . The device under test 4 can execute at least a first application executed when communicating with the host under test 2 and a second application executed when communicating with the external host device 3.

上位制御装置5は、例えばコンピュータであり、通信装置1を制御したり、通信装置1を介して受信したデータを表示したりする。上位制御装置5と通信装置1との間の接続インターフェイスは任意である。例えば、上位制御装置5は、シリアル通信インターフェイスを介して通信装置1との間で通信をすることができる。   The host control device 5 is, for example, a computer, and controls the communication device 1 or displays data received via the communication device 1. The connection interface between the host controller 5 and the communication device 1 is arbitrary. For example, the host controller 5 can communicate with the communication device 1 via a serial communication interface.

[通信装置1の構成]
図2は、通信装置1の構成を示す図である。通信装置1は、第1デバイス機能部11と、第2デバイス機能部12と、ホスト機能部13と、受付部14と、記憶部15と、通信制御部16と、を有する。
第1デバイス機能部11は、被試験ホスト装置2との間で通信するためのUSBデバイス機能を有する。第2デバイス機能部12は、外部ホスト装置3との間で通信するためのUSBデバイス機能を有する。第1デバイス機能部11と第2デバイス機能部12とは、同等の機能を有しており、第1デバイス機能部11に外部ホスト装置3が接続され、第2デバイス機能部12に被試験ホスト装置2が接続されてもよい。ホスト機能部13は、被試験デバイス装置4との間で通信するためのUSBホスト機能を有する。
[Configuration of Communication Device 1]
FIG. 2 is a diagram illustrating a configuration of the communication device 1. The communication device 1 includes a first device function unit 11, a second device function unit 12, a host function unit 13, a reception unit 14, a storage unit 15, and a communication control unit 16.
The first device function unit 11 has a USB device function for communicating with the host apparatus 2 under test. The second device function unit 12 has a USB device function for communicating with the external host device 3. The first device function unit 11 and the second device function unit 12 have equivalent functions, the external host device 3 is connected to the first device function unit 11, and the host under test is connected to the second device function unit 12. The device 2 may be connected. The host function unit 13 has a USB host function for communicating with the device under test 4.

受付部14は、上位制御装置5が出力する通信装置1を制御するための制御信号を受信する。受付部14は、受信した制御信号を通信制御部16に通知する。   The accepting unit 14 receives a control signal for controlling the communication device 1 output from the host control device 5. The receiving unit 14 notifies the communication control unit 16 of the received control signal.

記憶部15は、ROM(Read Only Memory)及びRAM(Random Access Memory)等の記憶媒体を有している。記憶部15は、通信制御部16により実行されるプログラム、及び通信制御部16が動作する際に用いるデータを記憶している。記憶部15は、例えば、被試験ホスト装置2と被試験デバイス装置4との間で送受信される第1データの送受信に用いられる一以上の第1通信パイプの識別情報を、被試験ホスト装置2及び被試験デバイス装置4に関連付けてルーティングテーブルとして記憶している。また、記憶部15は、外部ホスト装置3と被試験デバイス装置4との間で送受信される第2データの送受信に用いられる一以上の第2通信パイプの識別情報を、外部ホスト装置3及び被試験デバイス装置4に関連付けて、ルーティングテーブルとして記憶している。   The storage unit 15 includes a storage medium such as a ROM (Read Only Memory) and a RAM (Random Access Memory). The storage unit 15 stores a program executed by the communication control unit 16 and data used when the communication control unit 16 operates. The storage unit 15 stores, for example, identification information of one or more first communication pipes used for transmission / reception of first data transmitted / received between the host device under test 2 and the device under test 4, the host device under test 2. And stored as a routing table in association with the device under test 4. The storage unit 15 also stores identification information of one or more second communication pipes used for transmission / reception of second data transmitted / received between the external host device 3 and the device under test 4, and the external host device 3 and the device under test. In association with the test device apparatus 4, it is stored as a routing table.

ここで、通信パイプとは、USBインターフェイスを介した物理的な接続の中に構成される論理的な接続を言う。被試験ホスト装置2と被試験デバイス装置4とが通信する際には、第1通信パイプが使用され、外部ホスト装置3と被試験デバイス装置4とが通信する際には、第2通信パイプが使用される。被試験ホスト装置2と被試験デバイス装置4、又は外部ホスト装置3と被試験デバイス装置4との間で複数のアプリケーションがデータを送受信する場合、アプリケーションごとに通信パイプが割り当てられる。   Here, the communication pipe refers to a logical connection configured in a physical connection via a USB interface. When the host device under test 2 and the device under test 4 communicate, the first communication pipe is used. When the external host device 3 communicates with the device under test 4, the second communication pipe is used. used. When a plurality of applications transmit and receive data between the host device under test 2 and the device under test 4 or between the external host device 3 and the device under test 4, a communication pipe is allocated for each application.

図3は、記憶部15に記憶されているルーティングテーブルの一例を示す図である。ルーティングテーブルにおいては、ホスト装置IDと、ホスト装置アプリIDと、デバイス装置IDと、デバイス装置アプリIDと、通信パイプIDとが関連付けられている。   FIG. 3 is a diagram illustrating an example of the routing table stored in the storage unit 15. In the routing table, a host device ID, a host device application ID, a device device ID, a device device application ID, and a communication pipe ID are associated with each other.

ホスト装置IDは、被試験ホスト装置2及び外部ホスト装置3のそれぞれを識別するための識別情報である。図3においては、被試験ホスト装置2のホスト装置IDが「1」、外部ホスト装置3のホスト装置IDが「2」とされている。
ホスト装置アプリIDは、被試験ホスト装置2及び外部ホスト装置3で実行される、被試験デバイス装置4が実行するアプリケーションとの間でデータを送受信するアプリケーションを特定するための識別情報である。被試験ホスト装置2及び外部ホスト装置3は、それぞれ複数のアプリケーションを同時に実行することができる。
The host device ID is identification information for identifying each of the host device under test 2 and the external host device 3. In FIG. 3, the host device ID of the host device 2 under test is “1”, and the host device ID of the external host device 3 is “2”.
The host device application ID is identification information for specifying an application that is executed by the host device under test 2 and the external host device 3 and that transmits / receives data to / from an application executed by the device device under test 4. Each of the host device under test 2 and the external host device 3 can simultaneously execute a plurality of applications.

デバイス装置IDは、被試験デバイス装置4を識別するための識別情報である。本実施形態においては、通信装置1に接続されているデバイス装置が被試験デバイス装置4だけなので、図3においてはデバイス装置IDが「1」のみとなっているが、通信装置1が複数のデバイス装置と接続される場合は、ルーティングテーブルに「1」以外のデバイス装置IDが含まれることになる。   The device apparatus ID is identification information for identifying the device under test 4. In the present embodiment, the device device connected to the communication device 1 is only the device under test 4, and therefore the device device ID is only “1” in FIG. 3, but the communication device 1 is a plurality of devices. When connected to a device, the device table ID other than “1” is included in the routing table.

デバイス装置アプリIDは、被試験デバイス装置4で実行される、被試験ホスト装置2が実行するアプリケーション及び外部ホスト装置3が実行するアプリケーションとの間でデータを送受信するアプリケーションを特定するための識別情報である。被試験デバイス装置4は、複数のアプリケーションを同時に実行することができる。図3に示す例においては、ホスト装置アプリIDが「1h」、「2h」、「3h」のそれぞれのアプリケーションと通信する被試験デバイス装置4のアプリケーションのデバイス装置アプリIDが、それぞれ「1d」、「2d」、「3d」となっている。   The device device application ID is identification information for specifying an application executed by the device under test 4 and executed by the host device under test 2 and an application that transmits and receives data between the application executed by the external host device 3. It is. The device under test 4 can simultaneously execute a plurality of applications. In the example illustrated in FIG. 3, the device device application IDs of the applications of the device under test 4 that communicate with the applications of the host device application ID “1h”, “2h”, and “3h” are “1d”, “2d” and “3d”.

通信パイプIDは、被試験ホスト装置2と被試験デバイス装置4、及び外部ホスト装置3と被試験デバイス装置4の間でデータを送受信する際に用いられる通信パイプを識別するための識別情報である。図3に示す例においては、ホスト装置アプリIDが「1h」、「2h」、「3h」のアプリケーションは、通信パイプIDが「1」、「2」、「3」の通信パイプを用いて、デバイス装置アプリIDが「1d」、「2d」、「3d」のアプリケーションとの間でデータを送受信することがわかる。
このように、記憶部15は、被試験ホスト装置2及び第1アプリケーションに関連付けて一以上の第1通信パイプの識別情報を記憶し、外部ホスト装置3及び第2アプリケーションに関連付けて一以上の第2通信パイプの識別情報を記憶している。
The communication pipe ID is identification information for identifying a communication pipe used when data is transmitted / received between the host device under test 2 and the device under test 4 and between the external host device 3 and the device under test 4. . In the example shown in FIG. 3, applications with host device application IDs “1h”, “2h”, and “3h” use communication pipes with communication pipe IDs “1”, “2”, and “3”. It can be seen that data is transmitted / received to / from applications having device device application IDs “1d”, “2d”, and “3d”.
As described above, the storage unit 15 stores identification information of one or more first communication pipes in association with the host device under test 2 and the first application, and stores one or more first communication pipes in association with the external host device 3 and the second application. 2 The identification information of the communication pipe is stored.

図4は、アプリケーションと通信パイプとの関係を示す模式図である。図4に示す例において、被試験ホスト装置2が実行する第1アプリケーション(アプリ#1h)と被試験デバイス装置4が実行する第1アプリケーション(アプリ#1d)とは、通信パイプ#1を用いてデータを送受信する。同様に、外部ホスト装置3が実行する第2アプリケーション(アプリ#2h)と被試験デバイス装置4が実行する第2アプリケーション(アプリ#2d)とは、通信パイプ#2を用いてデータを送受信する。   FIG. 4 is a schematic diagram illustrating a relationship between an application and a communication pipe. In the example shown in FIG. 4, the first application (application # 1h) executed by the host under test device 2 and the first application (application # 1d) executed by the device under test device 4 use the communication pipe # 1. Send and receive data. Similarly, the second application (application # 2h) executed by the external host device 3 and the second application (application # 2d) executed by the device under test 4 transmit and receive data using the communication pipe # 2.

通信制御部16は、図4に示す状態を確立する前に、被試験ホスト装置2との通信に用いられる一以上の通信パイプ#1の識別情報及び外部ホスト装置3との通信に用いられる一以上の通信パイプ#2の識別情報を、被試験デバイス装置4に通知する。被試験デバイス装置4は、通知された通信パイプを用いて、被試験ホスト装置2及び外部ホスト装置3のそれぞれとの間でデータを送受信することができる。   Before establishing the state shown in FIG. 4, the communication control unit 16 uses identification information of one or more communication pipes # 1 used for communication with the host apparatus 2 under test and communication with the external host apparatus 3. The above-described identification information of the communication pipe # 2 is notified to the device under test 4. The device under test 4 can transmit / receive data to / from the host device under test 2 and the external host device 3 using the notified communication pipe.

図2に戻って、通信制御部16について説明する。通信制御部16は、記憶部15に記憶されているルーティングテーブルを参照して、被試験ホスト装置2及び外部ホスト装置3と被試験デバイス装置4との間の接続状態を制御する。まず、通信制御部16は、被試験デバイス装置4と被試験ホスト装置2との通信を開始する際に、被試験デバイス装置4と被試験ホスト装置2との通信に用いられる一以上の第1通信パイプの識別情報を被試験デバイス装置4及び被試験ホスト装置2と取り交わす。また、通信制御部16は、被試験デバイス装置4と外部ホスト装置3との通信を開始する際に、被試験デバイス装置4と外部ホスト装置3との通信に用いられる一以上の第2通信パイプの識別情報を被試験デバイス装置4及び外部ホスト装置3と取り交わす。   Returning to FIG. 2, the communication control unit 16 will be described. The communication control unit 16 refers to the routing table stored in the storage unit 15 and controls the connection state between the host device under test 2 and the external host device 3 and the device under test 4. First, when the communication control unit 16 starts communication between the device under test 4 and the host under test 2, the communication control unit 16 uses one or more first devices used for communication between the device under test 4 and the host under test 2. The communication pipe identification information is exchanged with the device under test 4 and the host under test 2. In addition, the communication control unit 16 starts one or more second communication pipes used for communication between the device under test 4 and the external host device 3 when starting communication between the device under test 4 and the external host device 3. Is exchanged with the device under test 4 and the external host device 3.

通信制御部16は、被試験デバイス装置4と被試験ホスト装置2との通信が開始され、被試験デバイス装置4と外部ホスト装置3との通信が開始されると、第1デバイス機能部11が被試験ホスト装置2から受信した第1下りデータ、及び第2デバイス機能部12が外部ホスト装置3から受信した第2下りデータを、ホスト機能部13を介して被試験デバイス装置4に送信する。   When the communication between the device under test 4 and the host device under test 2 is started and the communication between the device under test 4 and the external host device 3 is started, the communication control unit 16 starts the communication with the first device function unit 11. The first downlink data received from the host device under test 2 and the second downlink data received by the second device function unit 12 from the external host device 3 are transmitted to the device under test device 4 via the host function unit 13.

この際、通信制御部16は、第1デバイス機能部11を介して受信した第1下りデータを、一以上の第1通信パイプを用いて被試験デバイス装置4に送信し、第2デバイス機能部12から受信した第2下りデータを、一以上の第2通信パイプを用いて被試験デバイス装置4に送信する。また、通信制御部16は、ホスト機能部13が受信した上りデータのうち、第1上りデータを、第1デバイス機能部11を介して被試験ホスト装置2に送信し、かつ第2上りデータを、第2デバイス機能部12を介して外部ホスト装置3に送信する。
以下、通信装置1の各種動作について説明する。
At this time, the communication control unit 16 transmits the first downlink data received via the first device function unit 11 to the device under test 4 using one or more first communication pipes, and the second device function unit The second downlink data received from 12 is transmitted to the device under test 4 using one or more second communication pipes. Further, the communication control unit 16 transmits the first uplink data among the uplink data received by the host function unit 13 to the host device under test 2 via the first device function unit 11, and the second uplink data. Then, the data is transmitted to the external host device 3 via the second device function unit 12.
Hereinafter, various operations of the communication device 1 will be described.

[割り込み制御]
図5は、被試験ホスト装置2と被試験デバイス装置4とが通信中に、外部ホスト装置3が被試験デバイス装置4との通信を開始する際の割り込み動作について説明するための模式図である。図6は、割り込み動作が発生する場合のシーケンス図である。図5(a)は、被試験ホスト装置2と被試験デバイス装置4とが2本の通信パイプ#1、#2を用いて通信をしている状態を示している。この状態で、外部ホスト装置3が通信装置1に接続されると、通信制御部16は、ルーティングテーブルを参照して、3本目の通信パイプ#3を用いて被試験デバイス装置4との通信を開始する。
[Interrupt control]
FIG. 5 is a schematic diagram for explaining an interrupt operation when the external host device 3 starts communication with the device under test 4 while the host device under test 2 and the device under test 4 are communicating. . FIG. 6 is a sequence diagram when an interrupt operation occurs. FIG. 5A shows a state in which the host apparatus 2 under test and the device under test 4 communicate using two communication pipes # 1 and # 2. In this state, when the external host device 3 is connected to the communication device 1, the communication control unit 16 refers to the routing table and communicates with the device under test 4 using the third communication pipe # 3. Start.

具体的には、通信制御部16は、被試験ホスト装置2と被試験デバイス装置4とが一以上の第1通信パイプ(通信パイプ#1、#2)で通信中に外部ホスト装置3からの通信要求を受けたことに応じて、被試験デバイス装置4に対して一以上の第2通信パイプ(通信パイプ#3)の識別情報を通知することにより、外部ホスト装置3と被試験デバイス装置4との間の通信パイプを使用する。   Specifically, the communication control unit 16 is connected to the host device under test 2 and the device under test 4 from the external host device 3 while communicating with one or more first communication pipes (communication pipes # 1 and # 2). In response to receiving the communication request, the identification information of one or more second communication pipes (communication pipe # 3) is notified to the device under test 4 to thereby provide the external host device 3 and the device under test 4 Use a communication pipe between.

図6を参照すると、まず、被試験ホスト装置2が被試験デバイス装置4と通信を開始する場合、被試験ホスト装置2は、通信装置1との間で通信パイプを使用するためのエニュメレーションを開始する。エニュメレーションとは、USBホスト装置及びUSBデバイス装置が、お互いを認識するための処理である。USBホスト装置である被試験ホスト装置2は、USBデバイス装置としての通信装置1が接続されたことを検出すると、通信装置1の属性を示すディスクリプタを取得するためのリクエストメッセージを通信装置1に送信する。通信装置1は、リクエストメッセージを受信したことに応じて、通信装置1の属性を被試験ホスト装置2に通知する。このようにして、被試験ホスト装置2と通信装置1との間のエニュメレーションが完了する。   Referring to FIG. 6, first, when the host under test 2 starts communication with the device under test 4, the host under test 2 enumerates for using the communication pipe with the communication device 1. To start. Enumeration is a process for the USB host device and the USB device device to recognize each other. When the host device under test 2 which is a USB host device detects that the communication device 1 as a USB device device is connected, the host device under test 2 transmits a request message to the communication device 1 for acquiring a descriptor indicating the attribute of the communication device 1. To do. In response to receiving the request message, the communication device 1 notifies the host device under test 2 of the attributes of the communication device 1. In this way, enumeration between the host device under test 2 and the communication device 1 is completed.

続いて、通信制御部16は、被試験ホスト装置2との間のエニュメレーションが完了すると、ルーティングテーブルを参照する。通信制御部16は、被試験ホスト装置2と被試験デバイス装置4とを接続する必要があることを認識し、被試験デバイス装置4との間の通信パイプを使用するためのエニュメレーションを開始する。通信装置1は、エニュメレーションにおいて、ルーティングテーブルを参照して選択した通信パイプを使用可とする。ルーティングテーブルによれば、被試験ホスト装置2と被試験デバイス装置4との間では、2つのアプリケーションを用いた通信が行われるので、通信装置1は、2つの通信パイプを使用可とする。   Subsequently, when the enumeration with the host apparatus under test 2 is completed, the communication control unit 16 refers to the routing table. The communication control unit 16 recognizes that it is necessary to connect the host device under test 2 and the device under test 4 and starts enumeration for using the communication pipe between the device under test 4 and the device under test 4. To do. The communication device 1 enables the communication pipe selected with reference to the routing table in enumeration. According to the routing table, since communication using two applications is performed between the host device under test 2 and the device under test 4, the communication device 1 can use two communication pipes.

通信装置1は、上記手順により、被試験ホスト装置2との間で通信パイプ#1を使用可とする。次に、通信装置1は、被試験デバイス装置4との間で通信パイプ#1'を使用可とする。通信パイプ#1'は、通信装置1と被試験ホスト装置2との間で通信パイプ#1が使用される場合に通信装置1と被試験デバイス装置4との間の通信に用いられる通信パイプである。続いて、通信装置1は、被試験ホスト装置2との間で通信パイプ#2を使用可とし、被試験デバイス装置4との間で通信パイプ#2'を使用可とする。   The communication device 1 can use the communication pipe # 1 with the host device 2 under test according to the above procedure. Next, the communication apparatus 1 enables the communication pipe # 1 ′ with the device under test 4. The communication pipe # 1 ′ is a communication pipe used for communication between the communication device 1 and the device under test 4 when the communication pipe # 1 is used between the communication device 1 and the host device under test 2. is there. Subsequently, the communication device 1 enables the communication pipe # 2 with the host device under test 2 and enables the communication pipe # 2 ′ with the device under test 4.

続いて、外部ホスト装置3が通信装置1に接続されると、外部ホスト装置3は、通信装置1との間で通信パイプを使用可能にするためのエニュメレーションを開始する。エニュメレーションが完了すると、通信装置1は、被試験デバイス装置4との間でエニュメレーションを行い、外部ホスト装置3との間で通信パイプ#3を使用可とし、被試験デバイス装置4との間で通信パイプ#3'を使用可とする。
以上の手順により、被試験ホスト装置2と被試験デバイス装置4との間での、通信パイプ#1を用いた第1のデータ通信、及び通信パイプ#2を用いた第2のデータ通信、並びに外部ホスト装置3と被試験デバイス装置4との間での、通信パイプ#3を用いるアプリケーションによる第3のデータ通信を開始することができる。
Subsequently, when the external host device 3 is connected to the communication device 1, the external host device 3 starts enumeration for making the communication pipe usable with the communication device 1. When the enumeration is completed, the communication apparatus 1 performs the enumeration with the device under test 4, enables the communication pipe # 3 with the external host device 3, and the device under test 4 Communication pipe # 3 'can be used.
By the above procedure, the first data communication using the communication pipe # 1 and the second data communication using the communication pipe # 2 between the host apparatus 2 under test and the device under test 4, and The third data communication by the application using the communication pipe # 3 between the external host device 3 and the device under test 4 can be started.

[データ吸収・転送]
続いて、通信装置1が、被試験ホスト装置2から受信したデータを吸収し、被試験デバイス装置4に届けることなく外部ホスト装置3に転送する処理が行われるデータ吸収・転送モードについて説明する。データ吸収・転送モードは、通信装置1が、ユーザにより指定された通信パイプの指定方向のペイロードデータを吸収・転送するモードであり、例えば、被試験ホスト装置2と被試験デバイス装置4との間で生じた問題の原因を調査するために用いられる。ユーザは、通信装置1のデータ吸収・転送モードを用いることで、例えば、アプリケーションが送信するコマンドを一時的に止めた状態での動作を観察することが可能になる。
[Data absorption / transfer]
Subsequently, a data absorption / transfer mode in which the communication device 1 absorbs data received from the host device under test 2 and transfers the data to the external host device 3 without delivering it to the device device under test 4 will be described. The data absorption / transfer mode is a mode in which the communication apparatus 1 absorbs / transfers payload data in a specified direction of a communication pipe specified by a user. For example, the data absorption / transfer mode is performed between the host apparatus 2 under test and the device under test 4. Used to investigate the cause of problems that occurred in By using the data absorption / transfer mode of the communication device 1, the user can observe the operation in a state where the command transmitted by the application is temporarily stopped, for example.

通信装置1は、例えば、受付部14が、データ吸収・転送モードに設定する指示、すなわち、被試験ホスト装置2から受信した第1下りデータの被試験デバイス装置4への送信を停止させる停止指示を受け付けると、データ吸収・転送モードを起動する。通信制御部16は、受付部14が上記の停止指示を受け付けると、一以上の第1通信パイプを用いて被試験ホスト装置2から受信した第1下りデータの被試験デバイス装置4への送信を停止する。そして、通信制御部16は、被試験ホスト装置2から受信した第1下りデータを、一以上の第2通信パイプを介して3に転送する。   For example, the communication apparatus 1 instructs the reception unit 14 to set the data absorption / transfer mode, that is, a stop instruction to stop transmission of the first downlink data received from the host device 2 to be tested to the device device 4 to be tested. When data is accepted, the data absorption / transfer mode is activated. When the receiving unit 14 receives the stop instruction, the communication control unit 16 transmits the first downlink data received from the host device under test 2 to the device under test 4 using one or more first communication pipes. Stop. Then, the communication control unit 16 transfers the first downlink data received from the host under test 2 to 3 via one or more second communication pipes.

図7は、データ吸収・転送モードの動作について説明するための模式図である。通信装置1は、第1デバイス機能部11が被試験ホスト装置2から被試験デバイス装置4に送信されたデータを受信すると、受信したデータを被試験デバイス装置4に送信することなく、第1デバイス機能部11から第2デバイス機能部12に折り返す。そして、通信装置1は、第2デバイス機能部12を介して、被試験ホスト装置2から受信したデータを外部ホスト装置3に送信する。外部ホスト装置3において、通信装置1から受信したデータを表示することで、ユーザは、被試験ホスト装置2が被試験デバイス装置4に対して送信しているデータの内容を確認することができる。この間、通信装置1が被試験デバイス装置4から受信したデータは、通常通りに被試験ホスト装置2に送信される。   FIG. 7 is a schematic diagram for explaining the operation in the data absorption / transfer mode. When the first device function unit 11 receives the data transmitted from the host device under test 2 to the device under test 4, the communication device 1 transmits the first data without transmitting the received data to the device under test 4. The function unit 11 returns to the second device function unit 12. Then, the communication device 1 transmits data received from the host device under test 2 to the external host device 3 via the second device function unit 12. By displaying the data received from the communication device 1 in the external host device 3, the user can confirm the content of the data that the host device under test 2 is transmitting to the device device under test 4. During this time, the data received by the communication apparatus 1 from the device under test 4 is transmitted to the host under test 2 as usual.

図8は、データ吸収・転送モードにおけるシーケンス図である。データ吸収・転送モードが起動されていない状態、すなわちインアクティベート状態において、被試験ホスト装置2が通信装置1を介して被試験デバイス装置4にデータを送信すると、被試験デバイス装置4は、データを受信したことを示すACKメッセージを通信装置1に送信する。通信装置1は、被試験デバイス装置4からACKメッセージを受信すると、被試験ホスト装置2にACKメッセージを送信する。これにより、被試験ホスト装置2は、送信したデータが被試験デバイス装置4に届いたことを認識し、次のデータを送信する。
なお、通信装置1は、被試験ホスト装置2からデータを受信したら直ちにACKメッセージ(図8における破線矢印)を返送し、引き続いて被試験デバイス装置4に受信したデータを送信する手順を実行してもよい。
FIG. 8 is a sequence diagram in the data absorption / transfer mode. When the host device under test 2 transmits data to the device under test device 4 via the communication device 1 in the state where the data absorption / transfer mode is not activated, that is, in the inactivated state, the device under test device 4 transmits the data. An ACK message indicating reception is transmitted to the communication device 1. When the communication apparatus 1 receives the ACK message from the device under test 4, the communication apparatus 1 transmits the ACK message to the host under test 2. As a result, the host apparatus under test 2 recognizes that the transmitted data has reached the device under test apparatus 4 and transmits the next data.
The communication apparatus 1 returns the ACK message (broken arrow in FIG. 8) immediately after receiving the data from the host apparatus 2 under test, and then executes the procedure for transmitting the received data to the device under test 4. Also good.

これに対して、データ吸収・転送モードが起動された状態、すなわちアクティベート状態において、被試験ホスト装置2が被試験デバイス装置4に対して送信したデータが通信装置1に届くと、通信装置1は、受信したデータを被試験デバイス装置4に送信することなく、被試験ホスト装置2に対してACKメッセージを送信し、受信したデータを外部ホスト装置3に転送する。これにより、被試験ホスト装置2は、送信したデータが被試験デバイス装置4に届いたと認識し、次のデータを送信する。通信装置1があたかも被試験デバイス装置4であるかのように振る舞いつつ、被試験ホスト装置2から受信したデータを外部ホスト装置3に転送することで、ユーザは、被試験ホスト装置2と被試験デバイス装置4との間の通信に不具合が生じた場合に、被試験ホスト装置2が送信するデータに問題がないかどうかを確認することができる。   In contrast, when the data absorption / transfer mode is activated, that is, in the activated state, when the data transmitted from the host device 2 under test to the device under test 4 reaches the communication device 1, the communication device 1 Without transmitting the received data to the device under test 4, an ACK message is transmitted to the host device under test 2, and the received data is transferred to the external host device 3. Thereby, the host under test 2 recognizes that the transmitted data has reached the device under test 4 and transmits the next data. By transferring the data received from the host device 2 under test to the external host device 3 while the communication device 1 behaves as if it is the device device under test 4, the user can communicate with the host device 2 under test and the device under test 2. When a problem occurs in communication with the device apparatus 4, it is possible to check whether there is a problem in the data transmitted by the host apparatus 2 under test.

なお、以上の説明においては、通信装置1が、被試験ホスト装置2から受信したデータを外部ホスト装置3に転送する場合について説明したが、通信装置1は、被試験デバイス装置4から受信したデータを外部ホスト装置3に転送してもよい。この場合、通信装置1は、被試験デバイス装置4からデータを受信したことに応じて、被試験デバイス装置4に対してACKメッセージを送信する。また、通信装置1は、通信装置1が受信したデータを被試験ホスト装置2に転送することなく、単にデータ吸収・破棄のみを行ってもよい。   In the above description, the communication device 1 transfers the data received from the host device under test 2 to the external host device 3. However, the communication device 1 receives the data received from the device device under test 4. May be transferred to the external host device 3. In this case, the communication apparatus 1 transmits an ACK message to the device under test 4 in response to receiving data from the device under test 4. Further, the communication device 1 may simply perform data absorption / discarding without transferring the data received by the communication device 1 to the host device 2 under test.

このように、通信装置1が、被試験ホスト装置2から受信したデータを外部ホスト装置3に転送するか、被試験デバイス装置4から受信したデータを外部ホスト装置3に転送するかを切り替えることができる場合、通信装置1は、外部ホスト装置3に対して、アプリケーション及び使用する通信パイプを切り替えるように指示する。外部ホスト装置3は、切り替えの指示を受けたことに応じて、使用するアプリケーションに対応する通信パイプを使用する。   In this way, the communication device 1 can switch between transferring data received from the host device under test 2 to the external host device 3 or transferring data received from the device device under test 4 to the external host device 3. If possible, the communication device 1 instructs the external host device 3 to switch the application and the communication pipe to be used. The external host device 3 uses a communication pipe corresponding to the application to be used in response to receiving the switching instruction.

[データ挿入]
続いて、被試験ホスト装置2が被試験デバイス装置4に送信したデータの代わりに、外部ホスト装置3が送信したデータを被試験デバイス装置4に送信するデータ挿入モードについて説明する。データ挿入モードは、ユーザにより指定された通信パイプの指定方向に、指定されたペイロードデータを含むデータパケットを送信するモードである。ユーザは、データ挿入モードと上記のデータ吸収・転送モードとを同時に使用することができる。データ挿入モードにおいて、通信制御部16は、一以上の第2通信パイプを介して外部ホスト装置3から受信した第2下りデータを、一以上の第1通信パイプを介して被試験デバイス装置4に送信する。通信制御部16は、一以上の第1通信パイプを介して被試験デバイス装置4から受信した上りデータを、一以上の第2通信パイプを介して外部ホスト装置3に送信してもよい。
[Data Insertion]
Next, a data insertion mode in which data transmitted by the external host device 3 is transmitted to the device under test 4 instead of data transmitted from the host under test 2 to the device under test 4 will be described. The data insertion mode is a mode for transmitting a data packet including designated payload data in a designated direction of a communication pipe designated by a user. The user can use the data insertion mode and the data absorption / transfer mode simultaneously. In the data insertion mode, the communication control unit 16 transmits the second downlink data received from the external host device 3 via one or more second communication pipes to the device under test 4 via one or more first communication pipes. Send. The communication control unit 16 may transmit the uplink data received from the device under test 4 via one or more first communication pipes to the external host device 3 via one or more second communication pipes.

図9は、データ挿入モードについて説明するための模式図である。通信装置1は、被試験ホスト装置2から被試験デバイス装置4に送信されたデータを受信すると、被試験ホスト装置2から送信されたデータを被試験デバイス装置4に送信することなく、通信パイプ#1を介して外部ホスト装置3から送信されたデータを被試験デバイス装置4に送信する。また、通信装置1は、被試験デバイス装置4から被試験ホスト装置2に送信されたデータを被試験ホスト装置2に送信することなく、被試験デバイス装置4から送信されたデータを外部ホスト装置3に送信する。なお、外部ホスト装置3からのデータ送信は、被試験ホスト装置2からのデータ送信に関係なく行われてもよい。   FIG. 9 is a schematic diagram for explaining the data insertion mode. When the communication apparatus 1 receives the data transmitted from the host under test 2 to the device under test 4, the communication apparatus 1 does not transmit the data transmitted from the host under test 2 to the device under test 4. The data transmitted from the external host device 3 via 1 is transmitted to the device under test 4. Further, the communication apparatus 1 does not transmit the data transmitted from the device under test 4 to the host under test 2 to the host under test 2, but transmits the data transmitted from the device under test 4 to the external host device 3. Send to. The data transmission from the external host device 3 may be performed regardless of the data transmission from the host device 2 under test.

この際、外部ホスト装置3が、被試験ホスト装置2と同等の手順でデータ通信を行うことで、被試験デバイス装置4は、被試験ホスト装置2とデータを送受信している状態ではないにもかかわらず、被試験ホスト装置2との間でデータを送受信する時と同じ手順で、外部ホスト装置3との間でデータ通信を行うことができる。なお、通信装置1は、被試験デバイス装置4から受信したデータを、外部ホスト装置3の代わりに上位制御装置5に対して送信し、上位制御装置5から送信されたデータを被試験デバイス装置4に送信してもよい。   At this time, the external host device 3 performs data communication in the same procedure as the host device under test 2, so that the device under test device 4 is not in a state of transmitting / receiving data to / from the host device under test 2. Regardless, data communication with the external host device 3 can be performed in the same procedure as when data is transmitted to and received from the host device 2 under test. The communication device 1 transmits data received from the device under test 4 to the host control device 5 instead of the external host device 3, and the data transmitted from the host control device 5 is transmitted to the device under test 4. May be sent to.

図10は、データ挿入モードにおけるシーケンス図である。データ挿入モードがインアクティブ状態である間、通信装置1は、被試験ホスト装置2から送信されたデータを被試験デバイス装置4に転送し、被試験デバイス装置4から送信されたACKメッセージを被試験ホスト装置2に転送する。
なお、通信装置1は、被試験ホスト装置2からデータを受信したら直ちにACKメッセージ(図10における破線矢印)を返送し、引き続いて被試験デバイス装置4に受信したデータを送信する手順を実行してもよい。
FIG. 10 is a sequence diagram in the data insertion mode. While the data insertion mode is in the inactive state, the communication apparatus 1 transfers the data transmitted from the host device under test 2 to the device under test 4 and receives the ACK message transmitted from the device under test 4 under test. Transfer to the host device 2.
The communication device 1 returns the ACK message (broken arrow in FIG. 10) immediately after receiving the data from the host device 2 under test, and subsequently executes the procedure for transmitting the received data to the device under test 4. Also good.

これに対して、データ挿入モードがアクティブ状態になると、通信装置1は、被試験ホスト装置2から受信したデータを被試験デバイス装置4に転送せず、外部ホスト装置3から受信したデータを被試験デバイス装置4に送信する。そして、通信装置1は、被試験デバイス装置4から受信したデータを被試験ホスト装置2に転送せず、受信したデータを外部ホスト装置3に転送する。外部ホスト装置3は、受信したデータを表示する。このようにすることで、ユーザは、被試験デバイス装置4が送信したデータに問題がないかどうかを確認することができる。   On the other hand, when the data insertion mode becomes active, the communication device 1 does not transfer the data received from the host device under test 2 to the device under test device 4 and does not transfer the data received from the external host device 3 to the device under test. It transmits to the device apparatus 4. Then, the communication apparatus 1 does not transfer the data received from the device under test 4 to the host under test 2 but transfers the received data to the external host 3. The external host device 3 displays the received data. By doing in this way, the user can confirm whether there is no problem in the data transmitted by the device under test 4.

[本実施形態における効果]
以上説明したように、本実施形態に係る通信装置1においては、第1デバイス機能部11が被試験ホスト装置2から受信した第1下りデータ、及び第2デバイス機能部12が外部ホスト装置3から受信した第2下りデータを、ホスト機能部13を介して被試験デバイス装置4に送信する。このようにすることで、デバイス装置である被試験デバイス装置4を、複数のホスト装置である被試験ホスト装置2及び外部ホスト装置3と同時に接続することが可能になる。
[Effect in this embodiment]
As described above, in the communication device 1 according to the present embodiment, the first downlink data received by the first device function unit 11 from the host device under test 2 and the second device function unit 12 received from the external host device 3. The received second downlink data is transmitted to the device under test 4 via the host function unit 13. In this way, the device under test 4 that is a device device can be connected simultaneously with the host device under test 2 and the external host device 3 that are a plurality of host devices.

また、通信制御部16は、被試験ホスト装置2と被試験デバイス装置4とが通信中に外部ホスト装置3からの通信要求を受けたことに応じて、被試験デバイス装置4に対して、被試験デバイス装置4との通信に使用する通信パイプの識別情報を通知する。このようにすることで、ユーザは、被試験ホスト装置2と被試験デバイス装置4との通信状態に問題が発生した時点で外部ホスト装置3を接続して、被試験ホスト装置2と被試験デバイス装置4との間の通信状態を監視することが可能になる。   Further, the communication control unit 16 responds to the device under test 4 with respect to the device under test 4 in response to receiving a communication request from the external host device 3 during communication between the host under test 2 and the device under test 4. The communication pipe identification information used for communication with the test device apparatus 4 is notified. By doing so, the user connects the external host device 3 when a problem occurs in the communication state between the host device under test 2 and the device under test 4, and the host device under test 2 and the device under test are connected. It becomes possible to monitor the communication state with the device 4.

また、通信制御部16は、被試験ホスト装置2から受信したデータの被試験デバイス装置4への送信を停止させる停止指示の入力を受けたことに応じて、被試験ホスト装置2から受信したデータの被試験デバイス装置4への送信を停止する。そして、通信制御部16は、被試験ホスト装置2から受信したデータを外部ホスト装置3に転送する。このようにすることで、ユーザは、外部ホスト装置3において、被試験ホスト装置2から受信したデータの内容を観察し、被試験ホスト装置2と被試験デバイス装置4との間で生じた問題の原因を解析することができる。   Further, the communication control unit 16 receives the data received from the host under test 2 in response to receiving a stop instruction for stopping transmission of the data received from the host under test 2 to the device under test 4. Transmission to the device under test 4 is stopped. The communication control unit 16 transfers the data received from the host device under test 2 to the external host device 3. By doing so, the user observes the contents of the data received from the host device 2 under test in the external host device 3, and solves the problem that has occurred between the host device 2 under test and the device device under test 4. The cause can be analyzed.

以上、本発明を実施の形態を用いて説明したが、本発明の技術的範囲は上記実施の形態に記載の範囲には限定されない。上記実施の形態に、多様な変更又は改良を加えることが可能であることが当業者には明らかである。特に、装置の分散・統合の具体的な実施形態は以上に図示するものに限られず、その全部又は一部について、種々の付加等に応じて、又は、機能負荷に応じて、任意の単位で機能的又は物理的に分散・統合して構成することができる。   As mentioned above, although this invention was demonstrated using embodiment, the technical scope of this invention is not limited to the range as described in the said embodiment. It will be apparent to those skilled in the art that various modifications or improvements can be made to the above embodiment. In particular, the specific embodiments of the distribution / integration of the devices are not limited to those illustrated above, and all or a part thereof may be added in arbitrary units according to various additions or according to functional loads. It can be configured functionally or physically distributed and integrated.

例えば、上記においては、通信装置1が2台のUSBホスト装置と接続され、1台のUSBデバイス装置と接続される構成について説明したが、通信装置1に接続可能なUSBホスト装置及びUSBデバイス装置の数は、これに限らない。通信装置1は、3台以上のUSBホスト装置と接続され、2台以上のUSBデバイス装置と接続される構成であってもよい。   For example, in the above description, the communication device 1 is connected to two USB host devices and connected to one USB device device. However, the USB host device and the USB device device that can be connected to the communication device 1 have been described. The number of is not limited to this. The communication device 1 may be configured to be connected to three or more USB host devices and connected to two or more USB device devices.

また、上記の説明においては、主に、通信装置1が1本の通信パイプに対してデータ吸収・転送、データ挿入等のデータ処理を行う例について説明したが、通信装置1は、複数の通信パイプに対してデータ吸収・転送、データ挿入等のデータ処理を行ってもよい。また、データ吸収・破棄におけるデータ転送や、データ挿入におけるデータ送信においては、複数の通信パイプに同じデータを送信することも可能である。   In the above description, the example in which the communication device 1 mainly performs data processing such as data absorption / transfer and data insertion with respect to one communication pipe has been described. Data processing such as data absorption / transfer and data insertion may be performed on the pipe. Further, in data transfer in data absorption / discard or data transmission in data insertion, the same data can be transmitted to a plurality of communication pipes.

1 通信装置
2 被試験ホスト装置
3 外部ホスト装置
4 被試験デバイス装置
5 上位制御装置
11 第1デバイス機能部
12 第2デバイス機能部
13 ホスト機能部
14 受付部
15 記憶部
16 通信制御部
S 通信システム
DESCRIPTION OF SYMBOLS 1 Communication apparatus 2 Host apparatus to be tested 3 External host apparatus 4 Device apparatus to be tested 5 Host control apparatus 11 First device function section 12 Second device function section 13 Host function section 14 Reception section 15 Storage section 16 Communication control section S Communication system

Claims (13)

第1ホスト装置と通信する第1デバイス機能部と、
第2ホスト装置と通信する第2デバイス機能部と、
デバイス装置と通信するホスト機能部と、
前記第1デバイス機能部が前記第1ホスト装置から受信した第1下りデータ、及び前記第2デバイス機能部が前記第2ホスト装置から受信した第2下りデータを、前記ホスト機能部を介して前記デバイス装置に送信する通信制御部と、
を有する通信装置。
A first device function unit that communicates with the first host device;
A second device function unit that communicates with the second host device;
A host function unit that communicates with the device device;
The first downlink data received by the first device function unit from the first host device and the second downlink data received by the second device function unit from the second host device are transmitted via the host function unit. A communication control unit for transmitting to the device device;
A communication device.
前記ホスト機能部は、前記デバイス装置から受信した上りデータを受信し、
前記通信制御部は、前記ホスト機能部が受信した前記上りデータのうち、第1上りデータを、前記第1デバイス機能部を介して前記第1ホスト装置に送信し、かつ第2上りデータを、前記第2デバイス機能部を介して前記第2ホスト装置に送信する、
請求項1に記載の通信装置。
The host function unit receives uplink data received from the device device,
The communication control unit transmits first uplink data among the uplink data received by the host function unit to the first host device via the first device function unit, and second uplink data, Transmitting to the second host device via the second device function unit;
The communication apparatus according to claim 1.
前記通信制御部は、前記第1デバイス機能部を介して受信した前記第1下りデータを、一以上の第1通信パイプを用いて前記デバイス装置に送信し、前記第2デバイス機能部から受信した前記第2下りデータを、一以上の第2通信パイプを用いて前記デバイス装置に送信する、
請求項1又は2に記載の通信装置。
The communication control unit transmits the first downlink data received via the first device function unit to the device apparatus using one or more first communication pipes and receives the first downlink data from the second device function unit. Transmitting the second downlink data to the device device using one or more second communication pipes;
The communication apparatus according to claim 1 or 2.
前記第1ホスト装置と前記デバイス装置との間で送受信される第1データの送受信に用いられる前記一以上の第1通信パイプの識別情報を、前記第1ホスト装置及び前記デバイス装置に関連付けて記憶し、前記第2ホスト装置と前記デバイス装置との間で送受信される第2データの送受信に用いられる前記一以上の第2通信パイプの識別情報を、前記第2ホスト装置及び前記デバイス装置に関連付けて記憶する記憶部をさらに有する、
請求項3に記載の通信装置。
The identification information of the one or more first communication pipes used for transmission / reception of first data transmitted / received between the first host device and the device device is stored in association with the first host device and the device device. The identification information of the one or more second communication pipes used for transmission / reception of second data transmitted / received between the second host device and the device device is associated with the second host device and the device device. A storage unit for storing
The communication apparatus according to claim 3.
前記デバイス装置は、少なくとも第1アプリケーション及び第2アプリケーションを実行し、
前記記憶部は、前記第1ホスト装置及び前記第1アプリケーションに関連付けて前記一以上の第1通信パイプの識別情報を記憶し、前記第2ホスト装置及び前記第2アプリケーションに関連付けて前記一以上の第2通信パイプの識別情報を記憶する、
請求項4に記載の通信装置。
The device apparatus executes at least a first application and a second application,
The storage unit stores identification information of the one or more first communication pipes in association with the first host device and the first application, and associates with the one or more first communication devices in association with the second host device and the second application. Storing identification information of the second communication pipe;
The communication apparatus according to claim 4.
前記通信制御部は、前記第1ホスト装置との通信に用いられる前記一以上の第1通信パイプの識別情報及び前記第2ホスト装置との通信に用いられる前記一以上の第2通信パイプの識別情報を、前記デバイス装置に通知する、
請求項3から5のいずれか1項に記載の通信装置。
The communication control unit includes identification information of the one or more first communication pipes used for communication with the first host device and identification of the one or more second communication pipes used for communication with the second host device. Inform the device device of information,
The communication apparatus according to any one of claims 3 to 5.
前記通信制御部は、前記第1ホスト装置と前記デバイス装置とが前記一以上の第1通信パイプで通信中に前記第2ホスト装置からの通信要求を受けたことに応じて、前記デバイス装置に対して前記一以上の第2通信パイプの識別情報を通知する、
請求項6に記載の通信装置。
The communication control unit receives the communication request from the second host device during communication between the first host device and the device device via the one or more first communication pipes. To notify the identification information of the one or more second communication pipes;
The communication apparatus according to claim 6.
前記第1ホスト装置から受信した前記第1下りデータの前記デバイス装置への送信を停止させる停止指示を受け付ける受付部をさらに有し、
前記通信制御部は、前記受付部が前記停止指示を受け付けると、前記一以上の第1通信パイプを用いて前記第1ホスト装置から受信した前記第1下りデータの前記デバイス装置への送信を停止する、
請求項3から7のいずれか1項に記載の通信装置。
A reception unit that receives a stop instruction to stop transmission of the first downlink data received from the first host device to the device device;
The communication control unit stops transmission of the first downlink data received from the first host device to the device device using the one or more first communication pipes when the receiving unit receives the stop instruction. To
The communication apparatus according to any one of claims 3 to 7.
前記通信制御部は、前記一以上の第1通信パイプを介して前記第1ホスト装置から受信した前記第1下りデータを、前記一以上の第2通信パイプを介して前記第2ホスト装置に転送する、
請求項8に記載の通信装置。
The communication control unit transfers the first downlink data received from the first host device via the one or more first communication pipes to the second host device via the one or more second communication pipes. To
The communication apparatus according to claim 8.
前記通信制御部は、前記一以上の第2通信パイプを介して前記第2ホスト装置から受信した前記第2下りデータを、前記一以上の第1通信パイプを介して前記デバイス装置に送信する、
請求項8又は9に記載の通信装置。
The communication control unit transmits the second downlink data received from the second host device via the one or more second communication pipes to the device device via the one or more first communication pipes;
The communication apparatus according to claim 8 or 9.
ホスト機能を有するコンピュータと、前記コンピュータと通信する通信装置と、を備える通信システムであって、
前記通信装置は、
ホスト装置と通信する第1デバイス機能部と、
前記コンピュータと通信する第2デバイス機能部と、
デバイス装置と通信するホスト機能部と、
前記第1デバイス機能部が前記ホスト装置から受信した第1下りデータ、及び前記第2デバイス機能部が前記コンピュータから受信した第2下りデータを、前記ホスト機能部を介して前記デバイス装置に送信する通信制御部と、
を有する通信システム。
A communication system comprising a computer having a host function and a communication device that communicates with the computer,
The communication device
A first device function unit that communicates with the host device;
A second device function unit that communicates with the computer;
A host function unit that communicates with the device device;
The first device function unit transmits first downlink data received from the host device and the second device function unit transmits second downlink data received from the computer to the device device via the host function unit. A communication control unit;
A communication system.
第1ホスト装置、第2ホスト装置及びデバイス装置と接続される通信装置が実行する通信方法であって、
前記第1ホスト装置から第1下りデータを受信するステップと、
前記第2ホスト装置から第2下りデータを受信するステップと、
前記第1ホスト装置から受信した第1下りデータ、及び前記第2ホスト装置から受信した第2下りデータを前記デバイス装置に送信するステップと、
を有する通信方法。
A communication method executed by a communication device connected to a first host device, a second host device, and a device device,
Receiving first downlink data from the first host device;
Receiving second downlink data from the second host device;
Transmitting the first downlink data received from the first host device and the second downlink data received from the second host device to the device device;
A communication method.
第1ホスト装置、第2ホスト装置及びデバイス装置と接続される通信装置が有するコンピュータが実行するプログラムであって、
前記第1ホスト装置から第1下りデータを受信するステップと、
前記第2ホスト装置から第2下りデータを受信するステップと、
前記第1ホスト装置から受信した第1下りデータ、及び前記第2ホスト装置から受信した第2下りデータを前記デバイス装置に送信するステップと、
を有するプログラム。
A program executed by a computer included in a communication device connected to the first host device, the second host device, and the device device,
Receiving first downlink data from the first host device;
Receiving second downlink data from the second host device;
Transmitting the first downlink data received from the first host device and the second downlink data received from the second host device to the device device;
A program with
JP2016002844A 2016-01-08 2016-01-08 Communication device, communication system, communication method, and program Pending JP2017123117A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2016002844A JP2017123117A (en) 2016-01-08 2016-01-08 Communication device, communication system, communication method, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2016002844A JP2017123117A (en) 2016-01-08 2016-01-08 Communication device, communication system, communication method, and program

Publications (1)

Publication Number Publication Date
JP2017123117A true JP2017123117A (en) 2017-07-13

Family

ID=59305891

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2016002844A Pending JP2017123117A (en) 2016-01-08 2016-01-08 Communication device, communication system, communication method, and program

Country Status (1)

Country Link
JP (1) JP2017123117A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2001245017A (en) * 2000-02-28 2001-09-07 Ando Electric Co Ltd Usb simulation device and storage medium
JP2001256172A (en) * 2000-03-13 2001-09-21 Denso Corp Usb system, device for sub host management, hub device and usb host selector
JP2002342255A (en) * 2001-05-14 2002-11-29 Matsushita Electric Ind Co Ltd Device for connecting usb device
JP2009049550A (en) * 2007-08-15 2009-03-05 Hitachi Ltd Gateway device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2001245017A (en) * 2000-02-28 2001-09-07 Ando Electric Co Ltd Usb simulation device and storage medium
JP2001256172A (en) * 2000-03-13 2001-09-21 Denso Corp Usb system, device for sub host management, hub device and usb host selector
JP2002342255A (en) * 2001-05-14 2002-11-29 Matsushita Electric Ind Co Ltd Device for connecting usb device
JP2009049550A (en) * 2007-08-15 2009-03-05 Hitachi Ltd Gateway device

Similar Documents

Publication Publication Date Title
WO2023284699A1 (en) Protocol stack data transmission method based on linux system, and computer device and storage medium
EP3176980B1 (en) Unified server communication method, baseboard management controller and server
KR101820392B1 (en) Method, device and system for establishing data connection
CN107908589B (en) I3C communication verification system and method for verifying slave device and master-slave device
CN110430016B (en) Data receiving method and device and optical module
US8407390B2 (en) Method and apparatus for data processing
US9832279B2 (en) Station, target apparatus, initiator apparatus, communication system, and communication method
CN103650401A (en) Internal communication method for mobile terminal
US20160077986A1 (en) Electronic apparatus providing real-time switching and sharing of usb electronic devices among hosts
CN104536853B (en) A kind of device ensureing dual controller storage device resource continuous availability
CN110505517A (en) Data transmission method, system and equipment
CN103885910B (en) The method that many equipment carry out IIC communications under holotype
CN109116832A (en) Vehicle diagnostic data wireless communication method
CN109800202B (en) PCIE (peripheral component interface express) -based data transmission system, method and device
JP2017123117A (en) Communication device, communication system, communication method, and program
EP4280415A1 (en) Charging control method and apparatus, electronic device, and charger
CN112020155A (en) Information indicating, receiving and sending method, network equipment and terminal
EP3694151A1 (en) Terminal network sharing method, apparatus, air conditioning adjustment device, and storage medium
US9619005B2 (en) Apparatus and method for saving power of USB device
CN109618354A (en) A kind of Wi-Fi receiving and sending control method and device
CN104065845A (en) Information Processing Device Information Processing Method
CN116383116A (en) Communication method and device based on SPI bus
WO2016015614A1 (en) Ciphertext sending method, ciphertext transmission method, mobile terminal and communication base station
CN114760193A (en) Main/standby negotiation method and device
CN113886296B (en) Data transmission method, device, equipment and storage medium

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20180315

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20181214

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20190115

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20190301

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20190806