JP2014143634A - Communication apparatus, method for controlling communication apparatus, and program - Google Patents

Communication apparatus, method for controlling communication apparatus, and program Download PDF

Info

Publication number
JP2014143634A
JP2014143634A JP2013012135A JP2013012135A JP2014143634A JP 2014143634 A JP2014143634 A JP 2014143634A JP 2013012135 A JP2013012135 A JP 2013012135A JP 2013012135 A JP2013012135 A JP 2013012135A JP 2014143634 A JP2014143634 A JP 2014143634A
Authority
JP
Japan
Prior art keywords
service
communication
server
role
communication device
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.)
Granted
Application number
JP2013012135A
Other languages
Japanese (ja)
Other versions
JP6271838B2 (en
Inventor
Hideaki Tachibana
秀明 橘
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2013012135A priority Critical patent/JP6271838B2/en
Priority to PCT/JP2014/050504 priority patent/WO2014115612A1/en
Priority to US14/338,230 priority patent/US9602579B2/en
Publication of JP2014143634A publication Critical patent/JP2014143634A/en
Application granted granted Critical
Publication of JP6271838B2 publication Critical patent/JP6271838B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W8/00Network data management
    • H04W8/005Discovery of network devices, e.g. terminals
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/51Discovery or management thereof, e.g. service location protocol [SLP] or web services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W84/00Network topologies
    • H04W84/02Hierarchically pre-organised networks, e.g. paging networks, cellular networks, WLAN [Wireless Local Area Network] or WLL [Wireless Local Loop]
    • H04W84/10Small scale networks; Flat hierarchical networks
    • H04W84/12WLAN [Wireless Local Area Networks]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W84/00Network topologies
    • H04W84/18Self-organising networks, e.g. ad-hoc networks or sensor networks
    • H04W84/20Master-slave selection or change arrangements

Abstract

PROBLEM TO BE SOLVED: To efficiently control the respective roles of communication apparatuses in a service executed between them and the respective roles of them in a layer different from the layer of the service.SOLUTION: A communication apparatus determines whether to operate as a base station or as a terminal. The communication apparatus determines to operate as a base station if the apparatus functions as a server of a service executed between the apparatus and another communication apparatus.

Description

本発明は、通信装置、通信装置の制御方法、プログラムに関する。   The present invention relates to a communication device, a communication device control method, and a program.

近年、デジタルカメラやプリンタなどの電子機器に無線LANステーション機能を搭載し、電子機器を通信装置として、無線LANに接続して使用するケースが増えてきている。例えば特許文献1には、デジタルカメラに無線LAN機能を搭載し、画像共有を容易にする方法が開示されている。   In recent years, there is an increasing number of cases where a wireless LAN station function is installed in an electronic device such as a digital camera or a printer, and the electronic device is used as a communication device connected to a wireless LAN. For example, Patent Document 1 discloses a method for facilitating image sharing by mounting a wireless LAN function in a digital camera.

またWi−Fi AllianceによりWi−Fi Direct(登録商標)という規格が制定された。Wi−Fi Direct(以下、WFD)では、各電子機器が無線LANアクセスポイントまたは無線LANステーションのいずれとして動作するかを決定するプロトコルが規定されている。前記プロトコルを実行することにより、電子機器のどちらが無線LANアクセスポイントになり、どちらが無線LANステーションになるかを自動的に決定できる。WEDを使用することで、アクセスポイントを別途用意する必要がなくなり、電子機器同士で直接通信して各種のサービス(画像共有、印刷など)を実行することができるので、ユーザの利便性が向上する。   In addition, a standard called Wi-Fi Direct (registered trademark) has been established by Wi-Fi Alliance. In Wi-Fi Direct (hereinafter, WFD), a protocol for determining whether each electronic device operates as a wireless LAN access point or a wireless LAN station is defined. By executing the protocol, it is possible to automatically determine which of the electronic devices is a wireless LAN access point and which is a wireless LAN station. By using the WED, there is no need to prepare an access point separately, and various services (image sharing, printing, etc.) can be performed by directly communicating with each other, improving user convenience. .

また、アプリケーションレイヤにおいて他装置が提供しているサービスの内容を検索する機能(サービスディスカバリ機能)が、Wi−Fi Directのオプション機能として規定されている。本サービスディスカバリ機能によれば、接続処理実行前に、接続相手となる電子機器が提供しているサービスの情報を知ることができ、ユーザの利便性が向上する。   In addition, a function (service discovery function) for searching for the contents of services provided by other devices in the application layer is defined as an optional function of Wi-Fi Direct. According to this service discovery function, it is possible to know information on services provided by an electronic device that is a connection partner before executing the connection process, and the convenience for the user is improved.

特開2011−35768号公報JP 2011-35768 A

上記従来技術では、WFDを用いた無線レイヤにおける接続制御と、無線レイヤよりも上位レイヤであるアプリケーションレイヤにおけるサービスの制御は独立している。そのため、アプリケーションレイヤにおけるサービス遂行にふさわしくない無線レイヤの役割が設定されてしまう可能性があった。   In the above prior art, connection control in the radio layer using WFD and service control in the application layer, which is a higher layer than the radio layer, are independent. For this reason, there is a possibility that a role of the wireless layer that is not suitable for service execution in the application layer is set.

また、アプリケーションレイヤでのサービスにおける役割が変更される度に、その都度無線レイヤの再接続を行うことは、処理の負荷が増えて非効率である。   Further, every time the role in the service in the application layer is changed, reconnection of the wireless layer each time increases the processing load and is inefficient.

そこで本発明は、通信装置間で実行するサービスにおける各通信装置の役割と、当該サービスのレイヤとは異なるレイヤにおける各通信装置の役割とを、効率的に制御する通信装置を提供することを目的とする。   Accordingly, an object of the present invention is to provide a communication device that efficiently controls the role of each communication device in a service executed between the communication devices and the role of each communication device in a layer different from the layer of the service. And

上記目的を達成するために、本発明の通信装置は、基地局として動作してネットワークを構築する構築手段と、端末として動作してネットワークに参加する参加手段と、前記基地局として動作するか、前記端末として動作するかを決定する決定手段と、他の通信装置との間で実行されるサービスのクライアントとして動作して、ファイルを当該他の通信装置に送信する送信手段と、他の通信装置との間で実行されるサービスのサーバとして動作して、当該他の通信装置から送信されるファイルを受信する受信手段とを有し、前記決定手段は、前記他の通信装置との間で実行されるサービスのサーバとして動作する場合、前記基地局として動作すると決定することを特徴とする。   In order to achieve the above object, the communication device of the present invention operates as a base station, constructs a network, operates as a terminal, participates in a network, and operates as the base station. A determination unit that determines whether to operate as the terminal; a transmission unit that operates as a client of a service executed between the other communication devices and transmits a file to the other communication device; and another communication device Receiving means for receiving a file transmitted from the other communication device, and the determining means is executed with the other communication device. When operating as a service server, it is determined to operate as the base station.

また、上記目的を達成するために、本発明の通信装置は、基地局として動作してネットワークを構築する構築手段と、端末として動作してネットワークに参加する参加手段と、前記基地局及び前記端末の何れかの役割で動作して、他の通信装置と通信を行う通信手段と、アプリケーションレイヤにおけるサービスを実行するための前記通信装置の役割を決定する決定手段と、前記決定手段によって決定された役割に従ってアプリケーションレイヤにおけるサービスを実行した後、前記通信手段による通信のための役割を維持した状態で、前記決定手段によって決定された役割を変更する変更手段とを有することを特徴とする。   In order to achieve the above object, the communication apparatus of the present invention includes a construction unit that operates as a base station to construct a network, a participation unit that operates as a terminal and participates in the network, the base station, and the terminal. Determined by the determining unit, a communication unit that communicates with another communication device, a determining unit that determines a role of the communication device for executing a service in an application layer, and And changing means for changing the role determined by the determining means in a state where the role for communication by the communication means is maintained after executing the service in the application layer according to the role.

本発明によれば、通信装置間で実行するサービスにおける各通信装置の役割と、当該サービスのレイヤとは異なるレイヤにおける各通信装置の役割とを、効率的に制御することができる。   ADVANTAGE OF THE INVENTION According to this invention, the role of each communication apparatus in the service performed between communication apparatuses and the role of each communication apparatus in a layer different from the layer of the said service can be controlled efficiently.

装置を構成するブロック図Block diagram of the device 装置内のソフトウェア機能ブロック図Software function block diagram in the device 本発明が適用されるネットワーク構成の一例を示す図The figure which shows an example of the network configuration to which this invention is applied 実施例1における動作シーケンス図Operation sequence diagram in Embodiment 1 実施例1における装置の動作フロー図Operation flow diagram of apparatus in embodiment 1

[実施例1]
以下、本実施形態に係る通信装置について、図面を参照しながら詳細に説明する。以下では、IEEE802.11シリーズに準拠した無線LANシステムを用いた例について説明するが、通信形態は必ずしもIEEE802.11準拠の無線LANには限らない。
[Example 1]
Hereinafter, the communication apparatus according to the present embodiment will be described in detail with reference to the drawings. In the following, an example using a wireless LAN system compliant with the IEEE 802.11 series will be described, but the communication form is not necessarily limited to the wireless LAN compliant with IEEE 802.11.

本実施形態に好適な事例におけるハードウェア構成について説明する。   A hardware configuration in a case suitable for the present embodiment will be described.

図1は本発明を適用できる実施形態に係る、後述の各装置の構成の一例を表すブロック図である。101は装置全体を示す。102は、記憶部103に記憶される制御プログラムを実行することにより装置全体を制御する制御部である。制御部102は、1つ又は複数のCPUやMPU等のプロセッサを含む。制御部102は、他の装置との間で通信パラメータの設定制御も行う。103は制御部102が実行する制御プログラムと、通信パラメータ等の各種情報を記憶する記憶部である。また、記憶部103には、通信装置で生成された、又は、外部装置から受信した、画像データやファイル等を記憶してもよい。記憶部103は、ROM,RAM,HDD,フラッシュメモリ等の各種メモリによって構成される。尚、後述する各種動作は、記憶部103に記憶された制御プログラムを制御部102が実行することにより行われる。   FIG. 1 is a block diagram showing an example of the configuration of each device described below according to an embodiment to which the present invention can be applied. Reference numeral 101 denotes the entire apparatus. A control unit 102 controls the entire apparatus by executing a control program stored in the storage unit 103. The control unit 102 includes one or more processors such as a CPU and an MPU. The control unit 102 also performs communication parameter setting control with other devices. A storage unit 103 stores a control program executed by the control unit 102 and various types of information such as communication parameters. Further, the storage unit 103 may store image data, files, and the like generated by the communication device or received from the external device. The storage unit 103 includes various memories such as a ROM, a RAM, an HDD, and a flash memory. Various operations to be described later are performed by the control unit 102 executing a control program stored in the storage unit 103.

104はIEEE802.11シリーズに準拠した無線LAN通信を行うための無線部である。105は各種表示を行う表示部でありLCDやLEDのように視覚で認知可能な情報の出力、あるいはスピーカなどの音出力が可能な機能を有する。表示部105は視覚情報および音情報の少なくともどちらか一方を出力する機能を備えるものである。   A wireless unit 104 performs wireless LAN communication conforming to the IEEE802.11 series. Reference numeral 105 denotes a display unit that performs various displays, and has a function capable of outputting visually recognizable information such as an LCD or LED, or outputting sound such as a speaker. The display unit 105 has a function of outputting at least one of visual information and sound information.

107はアンテナ制御部、そして108はアンテナであり、アンテナ108を制御して無線通信による信号を送受信する。109は、ユーザが各種入力等を行い、通信装置を操作するための操作部である。操作部109は、各種ボタンやタッチパネル等によって構成される。   Reference numeral 107 denotes an antenna control unit, and reference numeral 108 denotes an antenna. The antenna 108 is controlled to transmit and receive signals by wireless communication. An operation unit 109 is used by the user to perform various inputs and operate the communication apparatus. The operation unit 109 includes various buttons, a touch panel, and the like.

サービス提供部110は、通信機器が備えるアプリケーションレイヤのサービスを提供する機能を備えている。例えば、本通信機器がプリンタである場合は、印刷機能を提供し、デジタルカメラである場合は撮像機能を提供する。   The service providing unit 110 has a function of providing an application layer service included in the communication device. For example, when the communication device is a printer, a printing function is provided, and when the communication device is a digital camera, an imaging function is provided.

尚、図1は一例であり、通信装置101は図1に示すハードウェア構成以外のハードウェア構成を備えていてもよい。   FIG. 1 is an example, and the communication apparatus 101 may have a hardware configuration other than the hardware configuration shown in FIG.

図2は、後述の通信制御機能を実行するソフトウェア機能ブロックの構成の一例を表すブロック図である。201はソフトウェア機能ブロック全体を示す。202はDiscovery制御部であり、通信相手となる通信装置を検索する検索処理を動作させる。   FIG. 2 is a block diagram illustrating an example of a configuration of software function blocks that execute a communication control function described later. Reference numeral 201 denotes an entire software function block. A Discovery control unit 202 operates a search process for searching for a communication device as a communication partner.

203はGO Negotiation制御部である。Wi−Fi Directプロトコル仕様に基づいた制御を行い、通信装置間でどちらが無線LANアクセスポイントになり、どちらが無線LANステーションになるかといった無線レイヤにおける役割を決定する。Wi−Fi Directにおいては、無線LANアクセスポイント機能を実施する通信装置をP2Pグループオーナー(以下、GO)、無線LANステーション機能を実施する通信装置をP2Pクライアント(以下、CL)と称する。GOまたは無線LANアクセスポイントとなる場合は、後述の無線LANアクセスポイント機能制御部211が起動され、CLまたは無線LANステーションとなる場合は、後述の無線LANステーション機能制御部210が起動される。このGO NegotiationのプロトコルはWi−Fi Direct仕様で決定されている。本発明のポイントではないため、説明は割愛する。Wi−Fi Directでは、GOが構築したネットワークをP2Pグループと称する。本実施例でもネットワークのことをP2Pグループと記載する場合がある。本実施例においては、これらは同一の意味で記載されている。   Reference numeral 203 denotes a GO Negotiation control unit. Control based on the Wi-Fi Direct protocol specification is performed, and a role in the wireless layer such as which becomes a wireless LAN access point and which becomes a wireless LAN station between communication apparatuses is determined. In Wi-Fi Direct, a communication device that performs a wireless LAN access point function is referred to as a P2P group owner (hereinafter referred to as GO), and a communication device that performs a wireless LAN station function is referred to as a P2P client (hereinafter referred to as CL). When it becomes a GO or wireless LAN access point, a wireless LAN access point function control unit 211 described later is activated, and when it becomes a CL or wireless LAN station, a wireless LAN station function control unit 210 described later is activated. The GO Negotiation protocol is determined by the Wi-Fi Direct specification. Since it is not the point of this invention, description is omitted. In Wi-Fi Direct, a network constructed by GO is referred to as a P2P group. In this embodiment, the network may be described as a P2P group. In the present embodiment, these are described with the same meaning.

なお、本明細書では、P2Pグループオーナー(GO)、P2Pクライアント(CL)および役割が未決定の通信装置群をまとめて、P2Pデバイスと称す。   In this specification, a P2P group owner (GO), a P2P client (CL), and a communication device group whose role has not been determined are collectively referred to as a P2P device.

204はDHCPクライアント制御部であり、GO Negotiation制御部203において自通信装置の役割が無線LANステーションとなったときに起動される。205はDHCPサーバ制御部であり、GO Negotiation制御部203において自通信装置の役割が無線LANアクセスポイントとなった時に起動される。   Reference numeral 204 denotes a DHCP client control unit which is activated when the role of the own communication device becomes a wireless LAN station in the GO Negotiation control unit 203. Reference numeral 205 denotes a DHCP server control unit, which is activated when the role of the own communication device becomes a wireless LAN access point in the GO Negotiation control unit 203.

206はWPSエンローリ制御部であり、無線LANの通信のために必要な通信パラメ―タを、他のWPSレジストラ装置より受信する。DHCPクライアント制御部204と同様に、自通信装置の役割が無線LANステーションの時に動作する。207はWPSレジストラ制御部であり、無線LANの通信のために必要な通信パラメータを他のWPSエンローリ装置に提供する。DHCPサーバ制御部205と同様に、自通信装置の役割が無線LANアクセスポイントの時に動作する。尚、WPSレジストラによって提供される通信パラメータは、ネットワーク識別子としてのSSID、暗号鍵、暗号方式、認証鍵、認証方式等のパラメータである。   A WPS enrollee control unit 206 receives communication parameters necessary for wireless LAN communication from other WPS registrar devices. Similar to the DHCP client control unit 204, it operates when the role of its own communication device is a wireless LAN station. A WPS registrar control unit 207 provides communication parameters necessary for wireless LAN communication to other WPS enrollee devices. Similar to the DHCP server control unit 205, it operates when the role of its own communication device is a wireless LAN access point. The communication parameters provided by the WPS registrar are parameters such as an SSID as a network identifier, an encryption key, an encryption method, an authentication key, and an authentication method.

208は無線LANパケット受信部、209は無線LANパケット送信部であり、上位レイヤの通信プロトコルを含むあらゆるパケットの送受信をつかさどる。210は無線LANステーション機能制御部である。自通信装置が無線LANステーションとして動作するときの認証・暗号処理等を実施し、無線LANアクセスポイントとして動作する装置が構築した無線ネットワークに参加する。211は無線LANアクセスポイント機能制御部であり、自通信装置が無線LANアクセスポイント機能として動作するときに無線ネットワークを構築し、認証・暗号処理および通信相手装置の管理等を実施する。無線LANステーション機能制御部210および無線LANアクセスポイント機能制御部211は、どちらか一方の機能もしくは同時に動作することが可能である。   A wireless LAN packet receiving unit 208 and a wireless LAN packet transmitting unit 209 handle transmission / reception of all packets including upper layer communication protocols. Reference numeral 210 denotes a wireless LAN station function control unit. It performs authentication / encryption processing when the communication apparatus operates as a wireless LAN station, and participates in a wireless network constructed by an apparatus operating as a wireless LAN access point. A wireless LAN access point function control unit 211 constructs a wireless network when the communication apparatus operates as a wireless LAN access point function, and performs authentication / encryption processing, communication partner apparatus management, and the like. The wireless LAN station function control unit 210 and the wireless LAN access point function control unit 211 can operate either one function or simultaneously.

212はパケットルーティング制御部であり、無線LANアクセスポイント機能制御部211が動作しているときに、通信パケットをブリッジおよびルーティングする。213はデータ記憶部であり、ソフトウェアそのものおよび、無線LANパラメータや、前述のDHCPアドレステーブルおよびARPテーブル等の各種テーブルを記憶保持している。   A packet routing control unit 212 bridges and routes a communication packet when the wireless LAN access point function control unit 211 is operating. A data storage unit 213 stores and holds software itself, wireless LAN parameters, and various tables such as the aforementioned DHCP address table and ARP table.

214はサービスディスカバリ制御部であり、Wi−Fi Direct特有のサービスディスカバリ機能をつかさどる。サービスディスカバリ機能は、IEEE802.11uで定められたアクションフレームを送受信することにより、相手通信装置の保有しているサービス情報をやりとりする。具体的にはSD Queryを送信し、SD Responseを返答として受信する。もしくは、相手装置からのSD Queryを受信し、応答としてSD Responseを送信する。   A service discovery control unit 214 is responsible for a service discovery function unique to Wi-Fi Direct. The service discovery function exchanges service information held by the counterpart communication device by transmitting and receiving action frames defined by IEEE 802.11u. Specifically, an SD Query is transmitted, and an SD Response is received as a response. Alternatively, an SD Query from the partner apparatus is received and an SD Response is transmitted as a response.

215はP2P Invitation機能制御部であり、Wi−Fi Direct規格で定められたInvitation機能を制御する。本Invitation機能についてはWi−Fi Direct仕様に定められているため割愛するが、GO機器もしくはCL機器が役割の決まっていないP2PデバイスをP2Pクライアントとして接続を促す機能である。   A P2P invitation function control unit 215 controls the invitation function defined by the Wi-Fi Direct standard. The invitation function is omitted because it is defined in the Wi-Fi Direct specification, but it is a function that prompts a P2P device for which a GO device or CL device has no determined role as a P2P client.

216はアプリケーションレイヤにおけるサービスを実行するサービス実行部である。ここでのアプリケーションレイヤとは、OSI参照モデルにおける第5層以上の上位レイヤにおけるサービス提供層のことをさす。すなわちサービス実行部216は、印刷機能(印刷サービス)や画像ストリーミング機能(動画像ストリーミングサービス)や、ファイル転送機能(ファイル転送サービス)などを実行する。尚、ファイル転送サービスによって転送(送受信)されるファイルは、あらゆる形式のデータを含むことができる。   A service execution unit 216 executes a service in the application layer. Here, the application layer refers to a service providing layer in an upper layer above the fifth layer in the OSI reference model. That is, the service execution unit 216 executes a print function (print service), an image streaming function (moving image streaming service), a file transfer function (file transfer service), and the like. The file transferred (transmitted / received) by the file transfer service can include data of any format.

217はアプリケーションレイヤにおけるサービスを提供するサーバ部である。サーバ部217は、アプリケーションレイヤにおけるサービスを提供する提供装置(サーバ)の役割として通信装置を機能させる。サーバ部217は、画像ストリーミング受信や、ファイルデータの受信・蓄積を行い、Responderとして動作する。具体的には、例えばHTTP(Hypertext Transfer Protocol)サーバやFTP(File Transfer Protocol)サーバとして動作する。   A server unit 217 provides a service in the application layer. The server unit 217 causes the communication device to function as a providing device (server) that provides a service in the application layer. The server unit 217 receives image streaming and receives / stores file data, and operates as a responder. Specifically, for example, it operates as an HTTP (Hypertext Transfer Protocol) server or an FTP (File Transfer Protocol) server.

218はアプリケーションレイヤにおけるサービスを利用するクライアント部である。クライアント部218は、アプリケーションレイヤにおけるサービスを利用する利用装置(クライアント)の役割として通信装置を機能させる。画像ストリーミング送信や、ファイルデータの送信などを行い、transmitterとして動作する。具体的には、例えば、HTTPクライアントやFTPクライアントとして動作する。   A client unit 218 uses a service in the application layer. The client unit 218 causes the communication apparatus to function as a role of a utilization apparatus (client) that uses a service in the application layer. It performs image streaming transmission, file data transmission, etc., and operates as a transmitter. Specifically, for example, it operates as an HTTP client or an FTP client.

219は判断部である。アプリケーションレイヤと無線LANレイヤの整合性の判断や、無線レイヤを維持したままサービスを継続して実行可能か否か等、各種の判断処理を行う。   Reference numeral 219 denotes a determination unit. Various determination processes such as determination of consistency between the application layer and the wireless LAN layer and whether or not the service can be continuously executed while maintaining the wireless layer are performed.

なお、図2に示す全ての機能ブロックはソフトウェアによって提供されるものに限らず、ハードウェアによって提供されるようにしてもよい。そして、図2に示す各機能ブロックは、相互関係を有するものである。また、図2に示す各機能ブロックは一例であり、複数の機能ブロックが1つの機能ブロックを構成するようにしてもよいし、何れかの機能ブロックが更に複数の機能を行うブロックに分かれてもよい。   Note that all the functional blocks shown in FIG. 2 are not limited to those provided by software, but may be provided by hardware. Each functional block shown in FIG. 2 has a mutual relationship. Each functional block shown in FIG. 2 is an example, and a plurality of functional blocks may constitute one functional block, or any functional block may be further divided into blocks that perform a plurality of functions. Good.

図3は、本実施例の構成図である。   FIG. 3 is a configuration diagram of this embodiment.

通信装置A32(以下、STA−A)、通信装置B33(以下、STA−B)から構成されるネットワークA31(以下、ネットワークA)を示した図である。ネットワークAは、Wi−Fi Directを用いて形成された無線ネットワークであり、GOとして動作するSTA−A又はSTA−Bの何れかが構築したネットワークである。図3の全ての装置は、先に説明した図1、図2の構成を有している。   It is the figure which showed network A31 (henceforth network A) comprised from communication apparatus A32 (henceforth STA-A) and communication apparatus B33 (henceforth STA-B). Network A is a wireless network formed using Wi-Fi Direct, and is a network constructed by either STA-A or STA-B operating as GO. All the apparatuses shown in FIG. 3 have the configurations shown in FIGS. 1 and 2 described above.

本実施例では、STA−AとSTA−BがHTTP通信を用いて、STA−BからSTA−Aに向けて動画像ファイルの送信処理を実施し、その後、ファイルの転送方向を入れ替えて、STA−AからSTA−Bへ送信処理を実施するユースケースを想定する。なお、ファイル転送サービスで用いるプロトコルは、HTTPに限定されるものではくFTPなどその他のファイル転送プロトコルでも実施可能であり、本実施例はプロトコルを限定する意図はない。   In this embodiment, STA-A and STA-B use HTTP communication to perform moving image file transmission processing from STA-B to STA-A, and then switch the file transfer direction, and STA -Assume a use case in which transmission processing is performed from A to STA-B. The protocol used in the file transfer service is not limited to HTTP, but can be implemented by other file transfer protocols such as FTP, and this embodiment is not intended to limit the protocol.

図4は、各装置間の動作シーケンスを示す模式図である。STA−AおよびSTA−Bは、ユーザの入力処理により、サービス処理を開始する(F401)。図4の例では、開始されるサービスは、STA−BからSTA−Aへ動画像ファイルを送信する、ファイル転送サービスである。このとき、STA−Aでは、ユーザの操作によって、ファイル受信サービスの開始が指示される。一方、STA−Bでは、ユーザの操作によって、ファイル送信サービスの開始が指示されることになる。ユーザの指示を受けて、STA−Aは、無線通信を行う相手装置を検索する(F402)。そして、STA−Bが検索されたのち、ユーザ指示に従ってSTA−Bと無線接続を実施する(F403)。F402の検索処理及びF403の接続処理は、前述したWi−Fi Directの仕様に定められた方法を用いる。従って、これらの処理において、STA−AとSTA−Bとの間での無線レイヤにおける各装置の役割が決定される。即ち、STA−AとSTA−Bとの間で、どちらがWi−Fi DirectのGOになり、どちらがCLになるかが決定される。   FIG. 4 is a schematic diagram showing an operation sequence between the devices. STA-A and STA-B start service processing by user input processing (F401). In the example of FIG. 4, the service to be started is a file transfer service that transmits a moving image file from STA-B to STA-A. At this time, in STA-A, the start of the file reception service is instructed by a user operation. On the other hand, in STA-B, the start of the file transmission service is instructed by a user operation. In response to the user's instruction, the STA-A searches for a partner apparatus that performs wireless communication (F402). Then, after STA-B is searched, wireless connection with STA-B is performed according to the user instruction (F403). The search process of F402 and the connection process of F403 use a method defined in the Wi-Fi Direct specification described above. Therefore, in these processes, the role of each device in the radio layer between STA-A and STA-B is determined. That is, it is determined which of the STA-A and the STA-B is the Wi-Fi Direct GO and which is the CL.

この時、無線レイヤにおける各装置の役割は、実行されるサービスでの役割に応じて、自動的に決定される。具体的には、アプリケーションレイヤサーバ部217によってサービスのサーバとして動作する装置を、無線レイヤにおけるGOとして決定する。これは、サービスのサーバ機能を有する装置がGOとなり、無線基地局として動作することによって、サービスを実施する上で必要な処理、例えばTCP/IPにおけるアドレスの割り当て、通信ポート設定等を確実に行うことができるからである。図4の例では、ファイル転送サービスにおいて、ファイル受信を行うSTA−Aがサーバとして動作している。一方、ファイル転送サービスにおいてファイル送信を行うSTA−Bがクライアントとして動作している。従って、図4の例では、STA−AがGOとなる。   At this time, the role of each device in the wireless layer is automatically determined according to the role in the service to be executed. Specifically, the application layer server unit 217 determines a device operating as a service server as a GO in the wireless layer. This is because a device having a server function of a service becomes a GO and operates as a radio base station, so that processing necessary for implementing the service, for example, assignment of addresses in TCP / IP, communication port setting, etc., is reliably performed. Because it can. In the example of FIG. 4, in the file transfer service, the STA-A that performs file reception operates as a server. On the other hand, STA-B that performs file transmission in the file transfer service operates as a client. Therefore, in the example of FIG. 4, STA-A becomes GO.

次に、STA−AとSTA−B間においてサービスの検索を行う。検索方法は例えば、UPnP(Universal Plug and Play)で規定されるSSDPを利用する。(F404)。   Next, a service search is performed between STA-A and STA-B. For example, the search method uses SSDP defined by UPnP (Universal Plug and Play). (F404).

STA−Aは、サービスの検索が完了したら、サービスを実行するためのサーバ(図4の例ではHTTPサーバ)を起動する(F405)。そして提供するサービスに対応するポートを開けて、当該ポートへの接続の待ち受け処理を実施する。STA−Bは、サービスの検索が完了したら、サービスを実行するためにクライアント(図4の例ではHTTPクライアント)を起動する(F406)。   When the search for the service is completed, the STA-A activates a server (HTTP server in the example of FIG. 4) for executing the service (F405). Then, a port corresponding to the service to be provided is opened, and a process of waiting for connection to the port is performed. When the service search is completed, the STA-B activates a client (HTTP client in the example of FIG. 4) to execute the service (F406).

なお、各装置でのサーバ/クライアント起動とサービス検索の処理の順序は逆であってもよい。   Note that the order of server / client activation and service search in each device may be reversed.

STA−Bは、STA−Aにおいて開けられたポートに接続し、transmitterとしてSTA−Aに対して動画像ファイルの送信を行う。具体的に本実施例では、HTTP PUTやHTTP POSTを用いて動画像ファイルの送信を行う(F407)。   The STA-B connects to the port opened in the STA-A, and transmits a moving image file to the STA-A as a transmitter. Specifically, in the present embodiment, the moving image file is transmitted using HTTP PUT or HTTP POST (F407).

前記送信処理が完了した場合は、STA−AからSTA―Bへファイル転送完了を通知する(F408)。   When the transmission process is completed, STA-A notifies STA-B of the completion of file transfer (F408).

STA−BからSTA−Aへのファイル転送が完了した後、ユーザ操作により今度はSTA−AからSTA−Bに動画像ファイルの送信を行う場合を考える。即ち、実行するサービスにおける装置の役割(サーバかクライアントか)が入れ替わる。ここで開始されるサービスは、STA−AからSTA−Bへ動画像ファイルを送信する、ファイル転送サービスである。従って、F401とは逆に、STA−Bでは、ユーザの操作によって、ファイル受信サービスの開始が指示される。一方、STA−Aでは、ユーザの操作によって、ファイル送信サービスの開始が指示されることになる。これらの指示に応じて、各装置ではサービス処理が開始される(F409、F410)。   Consider a case where, after the file transfer from the STA-B to the STA-A is completed, a moving image file is transmitted from the STA-A to the STA-B by a user operation. That is, the role of the device (server or client) in the service to be executed is switched. The service started here is a file transfer service for transmitting a moving image file from STA-A to STA-B. Therefore, contrary to F401, in STA-B, the start of the file reception service is instructed by the user's operation. On the other hand, in STA-A, the start of the file transmission service is instructed by a user operation. In response to these instructions, each apparatus starts service processing (F409, F410).

その後、STA−Aは無線レイヤの接続状態と、実行すべきサービスの内容を確認する(F411)。これはサービスを実施する上で、無線レイヤの再構築が必要か否かを判断するためである。判断のアルゴリズムの説明については、後述のフローチャートで説明する。STA−Aは、無線レイヤの接続を維持した状態でサービスを実行可能な場合は、無線レイヤ及び通信ポートを変更せずに、アプリケーションレイヤでのサービスにおけるサーバとクライアントの役割のみを変更する。ここでサーバとクライアントの役割を変更する理由は、動画像ファイルの転送方向がF407とは逆になるため、STA−AはサーバのままではSTA−Bに能動的に動画像ファイルを転送することができないためである。   Thereafter, the STA-A confirms the connection state of the wireless layer and the content of the service to be executed (F411). This is for determining whether or not the radio layer needs to be reconstructed in order to implement the service. The determination algorithm will be described with reference to a flowchart described later. If the STA-A can execute the service while maintaining the wireless layer connection, the STA-A changes only the roles of the server and the client in the service at the application layer without changing the wireless layer and the communication port. The reason for changing the roles of the server and the client here is that the moving direction of the moving image file is opposite to that of F407, so that the STA-A actively transfers the moving image file to the STA-B as it is the server. This is because they cannot.

そこでSTA−Aは、STA−Bに対してサービス準備要求を送信する(F412)。本要求は、具体的にはSTA−Bにサービスを提供するサーバの起動を指示するものである。   Therefore, the STA-A transmits a service preparation request to the STA-B (F412). Specifically, this request instructs STA-B to start a server that provides a service.

STA−Bは、STA−Aに対して、サーバを起動することが可能か否かの応答を返す(F413)。   The STA-B returns a response indicating whether the server can be activated to the STA-A (F413).

なお、サービス準備要求を送信せずに、STA−Aは自律的にクライアントを起動しても良い。STA−Bも、サーバを検知できなくなった場合に、自律的にサーバを起動しても良い。   Note that the STA-A may autonomously activate the client without transmitting the service preparation request. STA-B may also autonomously start the server when the server cannot be detected.

STA−Aは、STA−BがHTTPサーバを起動できる場合、自身のHTTPサーバ機能を停止して、HTTPクライアント機能を起動する(F414)。一方、STA−Bは、STA−BがHTTPサーバを起動できる場合、HTTPクライアント機能を停止して、HTTPサーバ機能を起動する(F415)。なお、HTTPサーバ機能とHTTPクライアント機能を同時に立ち上げることが可能な場合は、必ずしも、HTTPクライアント機能を停止する必要はない。STA−Aはサービス接続が完了したら、動画像ファイルの送信を行う。本実施例では、HTTP PUTやHTTP POSTを用いて動画像ファイルの送信を行う。(F416)。また前記送信処理が完了した場合は、STA−BからSTA―Aへファイル転送完了を通知する(F417)。   When STA-B can start the HTTP server, STA-A stops its own HTTP server function and starts the HTTP client function (F414). On the other hand, if the STA-B can start the HTTP server, the STA-B stops the HTTP client function and starts the HTTP server function (F415). If the HTTP server function and the HTTP client function can be started simultaneously, it is not always necessary to stop the HTTP client function. When the service connection is completed, the STA-A transmits a moving image file. In the present embodiment, the moving image file is transmitted using HTTP PUT or HTTP POST. (F416). When the transmission process is completed, the STA-B notifies the STA-A of the completion of file transfer (F417).

以上説明したように、本実施例では、初回のサービス実行時などのように、無線レイヤのコネクションが存在していない場合には、HTTPサーバがGOとなるように制御する。そして、二回目のサービス実行時などのように、すでに無線レイヤのコネクションが存在している場合には、アプリケーションレイヤにおける役割を変更する場合でも、無線レイヤの役割は変更することなく、アプリケーションレイヤにおける役割だけを変更する。   As described above, in this embodiment, when there is no wireless layer connection, such as when the first service is executed, control is performed so that the HTTP server becomes GO. And when the wireless layer connection already exists, such as when the service is executed for the second time, even if the role in the application layer is changed, the role in the wireless layer is not changed. Change only the role.

図5は、本実施例の通信装置の動作を示すフローチャートである。本フローチャートの各ステップは、記憶部103に記憶されたプログラムを制御部102が実行することによって処理される。尚、以下の説明では、通信装置間で行われるアプリケーションレイヤのサービスとして、ファイル転送サービスを実行する場合を例に説明する。即ち、一方の通信装置がファイル送信サービスを行い、他方の通信装置がファイル受信サービスを実行することで、通信装置間でファイル転送サービスが行われる例について説明する。しかし、本実施例を適用できるサービスの種類は、ファイル転送サービスに限定されるものではない。   FIG. 5 is a flowchart showing the operation of the communication apparatus of this embodiment. Each step of this flowchart is processed by the control unit 102 executing a program stored in the storage unit 103. In the following description, a case where a file transfer service is executed as an application layer service performed between communication apparatuses will be described as an example. That is, an example will be described in which a file transfer service is performed between communication apparatuses by one communication apparatus performing a file transmission service and the other communication apparatus executing a file reception service. However, the types of services to which this embodiment can be applied are not limited to file transfer services.

S501において、通信装置は、ユーザの操作によってサービスの開始指示を受付ける。図5の例では、ファイル送信サービス又はファイル受信サービス何れかの開始がユーザによって指示されるものとする。   In step S501, the communication apparatus accepts a service start instruction by a user operation. In the example of FIG. 5, the start of either the file transmission service or the file reception service is instructed by the user.

S502において、通信装置は、S501において指示されたサービスを実行可能であるかどうかを判断する。ファイル送信サービスが選択されている場合には、HTTPクライアント機能を備えているかどうかを判断し、ファイル受信サービスが選択されている場合には、HTTPサーバ機能を備えているかどうかを判断する。S502における判断の結果、サービスを実行不可能である場合は、エラー処理を行い処理を終了する(S503)。一方、ステップS502においてサービスを実行可能であると判断された場合は、S504へ進む。   In S502, the communication apparatus determines whether the service instructed in S501 can be executed. When the file transmission service is selected, it is determined whether an HTTP client function is provided. When the file reception service is selected, it is determined whether an HTTP server function is provided. If the result of determination in S502 is that service cannot be executed, error processing is performed and processing is terminated (S503). On the other hand, if it is determined in step S502 that the service can be executed, the process proceeds to S504.

S504において、通信装置は、無線LANコネクションの有無を判断する。無線LANコネクションが存在しないと判断された場合は、通信装置は、S501においてファイル送信サービスが指示されたか、ファイル受信サービスが指示されたかを判断する(S505)。S505において、ファイル受信サービスが指示されたと判断された場合、通信装置は、無線レイヤの役割として、GOとなることを決定する(S510)。これはサービスのサーバ機能を有する装置が無線基地局になることによって、サービスを実施する上で必要な処理、例えばアドレス割り当て、通信ポート設定等が確実に行うことができるからである。S511において、通信装置は、通信相手となる通信装置との間で実行可能なサービスの検索を行う。本例においては、通信相手となる通信装置が、ファイル送信サービスを実行可能であるかどうかが検索される。検索方法は例えば、UPnP(Universal Plug and Play)で規定されるSSDPを利用して検索を行う。通信相手となる通信装置と所望のサービスが実行可能である場合は、当該サービスを実行するために、サーバを起動する(S512)。本例では、HTTPサーバを起動する。そして、HTTPサーバのポートを開けてHTTPクライアントからの接続を待ち、HTTPクライアントとの間でサービス接続を行う。この時、通信装置はResponderとしてサービスを実行する(S513)。なお、サーバを起動してからS511のサービス検索を実施しても構わない。   In step S504, the communication apparatus determines whether there is a wireless LAN connection. If it is determined that there is no wireless LAN connection, the communication apparatus determines whether a file transmission service is instructed in S501 or a file reception service is instructed (S505). If it is determined in S505 that the file reception service has been instructed, the communication apparatus determines to be GO as the role of the wireless layer (S510). This is because when the apparatus having the server function of the service becomes a wireless base station, processing necessary for implementing the service, such as address assignment and communication port setting, can be reliably performed. In S511, the communication apparatus searches for a service that can be executed with the communication apparatus that is the communication partner. In this example, it is searched whether or not the communication device as the communication partner can execute the file transmission service. As a search method, for example, the search is performed using SSDP defined by UPnP (Universal Plug and Play). When a desired service can be executed with a communication device as a communication partner, a server is started to execute the service (S512). In this example, the HTTP server is activated. Then, the port of the HTTP server is opened, a connection from the HTTP client is awaited, and a service connection is made with the HTTP client. At this time, the communication apparatus executes a service as a responder (S513). Note that the service search in S511 may be performed after the server is started.

S505において、ファイル送信サービスが指示されたと判断された場合、通信装置は、無線レイヤの役割として、CLとなることを決定する(S506)。その後、S507において、通信装置は、通信相手となる通信装置との間で実行可能なサービスの検索を行う。本例においては、通信相手となる通信装置が、ファイル受信サービスを実行可能であるかどうかが検索される。検索方法は例えば、UPnP(Universal Plug and Play)で規定されるSSDPを利用して検索を行う。(S507)。通信相手となる通信装置と所望のサービスが実行可能である場合は、当該サービスを実行するために、クライアントを起動する(S508)。本例では、HTTPクライアントを起動する。そして、HTTPサーバにおいて開けられたポートに接続し、HTTPサーバとの間でサービス接続を行う。この時、通信装置はtransmitterとしてサービスを実行する(S509)。なお、クライアントを起動してからS507のサービス検索を実施しても構わない。   If it is determined in S505 that the file transmission service has been instructed, the communication apparatus determines that the role of the wireless layer is CL (S506). Thereafter, in S507, the communication device searches for a service that can be executed with the communication device that is the communication partner. In this example, it is searched whether or not the communication device as the communication partner can execute the file reception service. As a search method, for example, the search is performed using SSDP defined by UPnP (Universal Plug and Play). (S507). If a desired service can be executed with the communication device as the communication partner, the client is started to execute the service (S508). In this example, an HTTP client is activated. And it connects to the port opened in the HTTP server, and makes a service connection with the HTTP server. At this time, the communication apparatus executes a service as a transmitter (S509). Note that the service search in S507 may be performed after starting the client.

S504において、無線LANコネクションが存在すると判断された場合は、S514へと進む。この場合は、図4のF411で説明したように、既に一度無線接続を完了しサービス処理を終えた後の、二回目のサービス処理の実行が指示された場合が考えられる。即ち、アプリケーションレイヤのサービスにおけるサーバ又はクライアントが起動中であることが考えられる。   If it is determined in S504 that a wireless LAN connection exists, the process proceeds to S514. In this case, as described in F411 of FIG. 4, there may be a case where the execution of the second service process is instructed after the wireless connection has already been completed and the service process has been completed. That is, it is conceivable that the server or client in the application layer service is running.

S514では、通信装置は、アプリケーションレイヤのサービスにおけるサーバが起動中であるか否かを判定する(S514)。   In S514, the communication apparatus determines whether the server in the application layer service is running (S514).

サーバが起動中である場合はS515に進み、通信装置は、S501においてファイル送信サービスが指示されたか、ファイル受信サービスが指示されたかを判断する。ファイル送信サービスが指示されたと判断された場合、S516へ進む。ファイル送信サービスを実行するためには、通信装置は今起動しているHTTPサーバからHTTPクライアントに役割を切り替える必要がある。本実施例では、アプリケーションレイヤの役割を切り替えるにあたって、既に無線レイヤの接続が存在する場合には、無線レイヤの再接続を行うことなく、アプリケーションレイヤの役割だけを切り替えるようにする。つまりは、無線ネットワーク、IPアドレスの設定等はそのままで、サーバとクライアントの役割のみ入れ替える。そこで、S516において、通信装置は通信相手となる通信装置に対してサービス準備要求を送信する。サービス準備要求は、HTTPサーバを起動させるための要求である。なお、サービス準備要求を送信せずに、サーバ機器は自律的にクライアントを起動しても良い。   If the server is active, the process advances to step S515, and the communication apparatus determines whether a file transmission service is instructed in step S501 or a file reception service is instructed. If it is determined that the file transmission service has been instructed, the process proceeds to S516. In order to execute the file transmission service, the communication device needs to switch the role from the currently activated HTTP server to the HTTP client. In this embodiment, when the role of the application layer is switched, if the wireless layer connection already exists, only the role of the application layer is switched without reconnecting the wireless layer. That is, only the roles of the server and the client are exchanged without changing the wireless network and IP address settings. Therefore, in S516, the communication apparatus transmits a service preparation request to the communication apparatus that is the communication partner. The service preparation request is a request for starting the HTTP server. Note that the server device may autonomously start the client without transmitting the service preparation request.

S517において、通信相手となる通信装置がサーバ機能を起動可能かどうか判断し、動作可能な場合にはHTTPクライアントを起動する(S518)。このとき、通信装置はtransmitterとしてサービスを実行する(S519)。尚、S517において、通信相手となる通信装置がサーバ機能を起動できないと判断された場合には、エラー処理を行い、処理を中止する(S523)。   In S517, it is determined whether or not the communication device that is the communication partner can start the server function, and if it is operable, the HTTP client is started (S518). At this time, the communication apparatus executes a service as a transmitter (S519). In S517, if it is determined that the communication device as the communication partner cannot start the server function, error processing is performed and the processing is stopped (S523).

S515において、ファイル受信サービスが指示されたと判断された場合は、通信装置はHTTPサーバを起動する必要があるが、既にサーバは起動中である。従って、役割変更の処理を特に行うことなく、S525へと進み、サービスを実行する。   If it is determined in S515 that the file reception service has been instructed, the communication apparatus needs to start the HTTP server, but the server is already running. Therefore, the process proceeds to S525 without performing any role change processing, and the service is executed.

S514において、サーバが起動中ではないと判断された場合、即ち、クライアントが起動中であると判断された場合、S520へ進む。S520において、通信装置は、S501においてファイル送信サービスが指示されたか、ファイル受信サービスが指示されたかを判断する。ファイル受信サービスが指示されたと判断された場合、S521へ進む。ファイル受信サービスを実行するためには、通信装置は今起動しているHTTPクライアントからHTTPサーバに役割を切り替える必要がある。先に説明したように、本実施例では、アプリケーションレイヤの役割を切り替えるにあたって、既に無線レイヤの接続が存在する場合には、無線レイヤの再接続を行うことなく、アプリケーションレイヤの役割だけを切り替えるようにする。そこで、S521において、通信装置は、通信相手となる通信装置から送られるサービス準備要求の受信を待機する。サービス準備要求は、HTTPサーバを起動させるための要求である。   If it is determined in S514 that the server is not active, that is, if it is determined that the client is active, the process proceeds to S520. In S520, the communication apparatus determines whether a file transmission service is instructed in S501 or a file reception service is instructed. If it is determined that the file reception service has been instructed, the process proceeds to S521. In order to execute the file reception service, the communication apparatus needs to switch the role from the currently activated HTTP client to the HTTP server. As described above, in this embodiment, when the role of the application layer is switched, when the connection of the wireless layer already exists, only the role of the application layer is switched without reconnecting the wireless layer. To. Therefore, in S521, the communication apparatus waits for reception of a service preparation request sent from the communication apparatus serving as a communication partner. The service preparation request is a request for starting the HTTP server.

サービス準備要求を受信すると、通信装置は、自装置においてHTTPサーバを起動可能であるかどうかを判断する(S522)。起動不可能である場合には、S523へ進み、エラー処理を行い、処理を中止する。HTTPサーバを起動可能であると判断されると、S524へ進む。S524において、通信装置は、HTTPサーバを起動する。そして、通信装置はサービスのResponderとしてサービスを実行する(S525)。   When receiving the service preparation request, the communication apparatus determines whether the HTTP server can be activated in the own apparatus (S522). If the activation is impossible, the process proceeds to S523, an error process is performed, and the process is stopped. If it is determined that the HTTP server can be activated, the process proceeds to S524. In S524, the communication device activates the HTTP server. Then, the communication apparatus executes the service as a service responder (S525).

S520において、ファイル送信サービスが指示されたと判断された場合は、通信装置はHTTPクライアントを起動する必要があるが、既にクライアントは起動中である。従って、役割変更の処理を特に行うことなく、S519へと進み、サービスを実行する。   If it is determined in S520 that the file transmission service has been instructed, the communication apparatus needs to activate the HTTP client, but the client is already active. Therefore, the process proceeds to S519 without performing the role changing process, and the service is executed.

なお、本フローチャートでは割愛したが、どのステップであってもユーザの意思により処理を中止することは可能である。   Although omitted in this flowchart, it is possible to stop the processing at any step by the user's intention.

以上説明した通り、本実施例では、初回のサービス実行時などのように、無線レイヤのコネクションが存在していない場合には、HTTPサーバがGOとなるように制御する。このように、アプリケーションレイヤの役割に応じて、無線レイヤにおける役割を決めるので、各レイヤにおける役割を効率的に制御することができる。特に、アプリケーションレイヤにおけるサーバ(例えばHTTPサーバ)が無線レイヤにおけるGOとして動作するので、TCP/IPネットワークの管理に適した役割を設定することができるようになる。   As described above, in this embodiment, when there is no wireless layer connection, such as when the first service is executed, the HTTP server is controlled to be GO. Thus, since the role in the wireless layer is determined according to the role of the application layer, the role in each layer can be controlled efficiently. In particular, since a server (for example, an HTTP server) in the application layer operates as a GO in the wireless layer, a role suitable for management of the TCP / IP network can be set.

また、二回目のサービス実行時などのように、すでに無線レイヤのコネクションが存在している場合には、アプリケーションレイヤにおける役割を変更する場合でも、無線レイヤの役割は変更することなく、アプリケーションレイヤにおける役割だけを変更する。これにより、処理の負荷を無駄に増やすことなく、効率的に各レイヤにおける役割を制御することができるようになる。   In addition, when a wireless layer connection already exists, such as when the service is executed for the second time, even if the role in the application layer is changed, the role in the wireless layer is not changed. Change only the role. As a result, it is possible to efficiently control the roles in each layer without unnecessarily increasing the processing load.

なお、図5のフローチャートには記載していないが、通信装置がクライアントとして動作する上で無線レイヤの再設定が必要な場合は無線ネットワークの再構築を実施してもよい。とくに第3の通信装置がネットワークに新たに参加してきた場合などはネットワークの再構築が必要となる。その場合は一旦ネットワークを切断した上で、改めて図5に示したフローチャートを実行することとなる。   Although not described in the flowchart of FIG. 5, the wireless network may be reconfigured when the wireless layer needs to be reset when the communication apparatus operates as a client. In particular, when the third communication device newly joins the network, the network needs to be reconstructed. In that case, the network is once disconnected and the flowchart shown in FIG. 5 is executed again.

[その他の実施例]
上記の実施例は、本発明を実施するための一例を示すものであり、本発明の趣旨を逸脱しない限り種々の変更が可能である。
[Other Examples]
The above embodiment shows an example for carrying out the present invention, and various modifications can be made without departing from the gist of the present invention.

上記実施例の通信装置は、デジタルカメラやプリンタ等に限らない。PCやタブレット端末であってもよく、携帯電話やスマートフォン等のモバイル端末であってもよい。また、複写機やスキャナ、FAX、複合機等の画像処理装置、テレビやレコーダー等のデジタル家電であってもよい。   The communication device of the above embodiment is not limited to a digital camera, a printer, or the like. It may be a PC or a tablet terminal, and may be a mobile terminal such as a mobile phone or a smartphone. Further, it may be an image processing apparatus such as a copying machine, a scanner, a FAX, or a multifunction machine, or a digital home appliance such as a television or a recorder.

また、上記実施例はIEEE802.11準拠の無線LANを例に説明した。しかしながら、本発明は、ワイヤレスUSB、MBOA、Bluetooth(登録商標)、UWB、ZigBee(登録商標)等の他の無線通信において実施してもよい。また、有線LAN等の有線通信媒体において実施してもよい。ここで、MBOAは、Multi Band OFDM Allianceの略である。また、UWBは、ワイヤレスUSB、ワイヤレス1394、WINETなどが含まれる。   The above embodiment has been described by taking an example of a wireless LAN compliant with IEEE 802.11. However, the present invention may be implemented in other wireless communications such as wireless USB, MBOA, Bluetooth (registered trademark), UWB, and ZigBee (registered trademark). Moreover, you may implement in wired communication media, such as wired LAN. Here, MBOA is an abbreviation for Multi Band OFDM Alliance. UWB includes wireless USB, wireless 1394, WINET, and the like.

更に、本発明は、以下の処理を実行することによっても実現される。即ち、上述した実施形態の機能を実現するソフトウェア(プログラム)をネットワーク又は各種記憶媒体を介してシステム或いは装置に供給し、そのシステム又は装置のコンピュータ(又はCPUやMPU等)がプログラムコードを読み出して実行する処理である。この場合、そのプログラム、及び該プログラムを記憶した記憶媒体は本発明を構成することになる。   Furthermore, the present invention is also realized by executing the following processing. That is, software (program) that realizes the functions of the above-described embodiments is supplied to a system or apparatus via a network or various storage media, and a computer (or CPU, MPU, etc.) of the system or apparatus reads the program code. It is a process to be executed. In this case, the program and the storage medium storing the program constitute the present invention.

31 ネットワークA
32 STA−A(Wi−Fi DirectのGO)
33 STA−B(Wi−Fi DirectのCL)
31 Network A
32 STA-A (Wi-Fi Direct GO)
33 STA-B (CL for Wi-Fi Direct)

Claims (12)

通信装置であって、
基地局として動作してネットワークを構築する構築手段と、
端末として動作してネットワークに参加する参加手段と、
前記基地局として動作するか、前記端末として動作するかを決定する決定手段と、
他の通信装置との間で実行されるサービスのクライアントとして動作して、ファイルを当該他の通信装置に送信する送信手段と、
他の通信装置との間で実行されるサービスのサーバとして動作して、当該他の通信装置から送信されるファイルを受信する受信手段と、
を有し、
前記決定手段は、前記他の通信装置との間で実行されるサービスのサーバとして動作する場合、前記基地局として動作すると決定することを特徴とする通信装置。
A communication device,
Construction means that operates as a base station to construct a network;
Participation means that operates as a terminal and joins the network;
Determining means for determining whether to operate as the base station or the terminal;
Operating as a client of a service executed with another communication device, and transmitting means for transmitting the file to the other communication device;
Receiving means for operating as a server for services executed with other communication devices and receiving files transmitted from the other communication devices;
Have
The said determination means determines to operate | move as said base station, when operate | moving as a server of the service performed between said other communication apparatuses.
前記ファイルの送信及び受信は、HTTPを用いて実行し、前記サーバはHTTPサーバであり、前記クライアントはHTTPクライアントであることを特徴とする請求項1記載の通信装置。   The communication apparatus according to claim 1, wherein transmission and reception of the file are performed using HTTP, the server is an HTTP server, and the client is an HTTP client. 前記他の通信装置との間で実行されるサービスは、ファイル転送サービスであることを特徴とする請求項1又は2に記載の通信装置。   The communication apparatus according to claim 1, wherein the service executed with the other communication apparatus is a file transfer service. ユーザによってファイルの受信の指示、又はファイルの送信の指示を受付ける受付手段を有し、
前記受付手段によってファイルの受信の指示を受付けた場合、前記サーバとして動作し、前記受付手段によってファイルの送信の指示を受付けた場合、前記クライアントとして動作することを特徴とする請求項1乃至3の何れか一項に記載の通信装置。
Having a reception means for receiving a file reception instruction or a file transmission instruction by the user;
4. The apparatus according to claim 1, wherein the server operates as the server when an instruction to receive a file is received by the reception unit, and operates as the client when an instruction to transmit a file is received by the reception unit. The communication apparatus as described in any one.
通信装置であって、
基地局として動作してネットワークを構築する構築手段と、
端末として動作してネットワークに参加する参加手段と、
前記基地局及び前記端末の何れかの役割で動作して、他の通信装置と通信を行う通信手段と、
アプリケーションレイヤにおけるサービスを実行するための前記通信装置の役割を決定する決定手段と、
前記決定手段によって決定された役割に従ってアプリケーションレイヤにおけるサービスを実行した後、前記通信手段による通信のための役割を維持した状態で、前記決定手段によって決定された役割を変更する変更手段と、
を有することを特徴とする通信装置。
A communication device,
Construction means that operates as a base station to construct a network;
Participation means that operates as a terminal and joins the network;
A communication means that operates in the role of either the base station or the terminal and communicates with another communication device;
Determining means for determining a role of the communication device for executing a service in an application layer;
A changing means for changing a role determined by the determining means after executing a service in an application layer according to the role determined by the determining means and maintaining a role for communication by the communication means;
A communication apparatus comprising:
前記決定手段によって決定される役割は、アプリケーションレイヤにおけるサービスを実行するためのサーバ又はクライアントであることを特徴とする請求項5記載の通信装置。   The communication apparatus according to claim 5, wherein the role determined by the determination unit is a server or a client for executing a service in an application layer. 前記変更手段は、前記決定手段によって決定された前記通信装置の役割がサーバであった場合には、クライアントに変更し、前記決定手段によって決定された前記通信装置の役割がクライアントであった場合には、サーバに変更することを特徴とする請求項6記載の通信装置。   When the role of the communication device determined by the determination unit is a server, the changing unit changes to a client, and when the role of the communication device determined by the determination unit is a client 7. The communication apparatus according to claim 6, wherein the communication apparatus is changed to a server. 前記アプリケーションレイヤにおけるサービスは、ファイル転送サービスであることを特徴とする請求項5乃至7の何れか一項に記載の通信装置。   The communication apparatus according to claim 5, wherein the service in the application layer is a file transfer service. 前記基地局及び前記端末は、IEEE802.11に準拠した無線LANにおける基地局及び端末であることを特徴とする請求項1乃至3の何れか一項に記載の通信装置。   The communication apparatus according to any one of claims 1 to 3, wherein the base station and the terminal are a base station and a terminal in a wireless LAN compliant with IEEE 802.11. 通信装置の制御方法であって、
基地局として動作してネットワークを構築する構築工程と、
端末として動作してネットワークに参加する参加工程と、
前記基地局として動作するか、前記端末として動作するかを決定する決定工程と、
他の通信装置との間で実行されるサービスのクライアントとして動作して、ファイルを当該他の通信装置に送信する送信工程と、
他の通信装置との間で実行されるサービスのサーバとして動作して、当該他の通信装置から送信されるファイルを受信する受信工程と、
を有し、
前記決定工程は、前記他の通信装置との間で実行されるサービスのサーバとして動作する場合、前記基地局として動作すると決定することを特徴とする通信装置の制御方法。
A communication device control method comprising:
A construction process that operates as a base station to construct a network;
A participation process that operates as a terminal and joins the network;
A determination step of determining whether to operate as the base station or the terminal;
A transmission step of operating as a client of a service executed with another communication device and transmitting a file to the other communication device;
A reception step of receiving a file transmitted from the other communication device, operating as a server of a service executed with the other communication device;
Have
The method for controlling a communication apparatus, wherein the determining step determines that the base station operates when operating as a server for a service executed with the other communication apparatus.
通信装置の制御方法であって、
基地局として動作してネットワークを構築する構築工程と、
端末として動作してネットワークに参加する参加工程と、
前記基地局及び前記端末の何れかの役割で動作して、他の通信装置と通信を行う通信工程と、
アプリケーションレイヤにおけるサービスを実行するための前記通信装置の役割を決定する決定工程と、
前記決定工程によって決定された役割に従ってアプリケーションレイヤにおけるサービスを実行した後、前記通信工程による通信のための役割を維持した状態で、前記決定工程によって決定された役割を変更する変更工程と、
を有することを特徴とする通信装置の制御方法。
A communication device control method comprising:
A construction process that operates as a base station to construct a network;
A participation process that operates as a terminal and joins the network;
A communication step of operating in the role of either the base station or the terminal and communicating with another communication device;
A determining step of determining a role of the communication device for executing a service in an application layer;
After executing the service in the application layer according to the role determined by the determination step, the change step of changing the role determined by the determination step while maintaining the role for communication by the communication step;
A method for controlling a communication apparatus, comprising:
請求項1乃至9の何れか一項に記載された通信装置として、コンピュータを動作させるためのプログラム。   The program for operating a computer as a communication apparatus as described in any one of Claims 1 thru | or 9.
JP2013012135A 2013-01-25 2013-01-25 COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM Active JP6271838B2 (en)

Priority Applications (3)

Application Number Priority Date Filing Date Title
JP2013012135A JP6271838B2 (en) 2013-01-25 2013-01-25 COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
PCT/JP2014/050504 WO2014115612A1 (en) 2013-01-25 2014-01-15 Communication apparatus, method for controlling communication apparatus, program
US14/338,230 US9602579B2 (en) 2013-01-25 2014-07-22 Communication apparatus, method for controlling the same, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2013012135A JP6271838B2 (en) 2013-01-25 2013-01-25 COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM

Publications (2)

Publication Number Publication Date
JP2014143634A true JP2014143634A (en) 2014-08-07
JP6271838B2 JP6271838B2 (en) 2018-01-31

Family

ID=51227404

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013012135A Active JP6271838B2 (en) 2013-01-25 2013-01-25 COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM

Country Status (3)

Country Link
US (1) US9602579B2 (en)
JP (1) JP6271838B2 (en)
WO (1) WO2014115612A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6271839B2 (en) * 2013-01-25 2018-01-31 キヤノン株式会社 COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
KR20190069247A (en) * 2017-12-11 2019-06-19 삼성전자주식회사 Electronic device for communication with external electronic device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005277937A (en) * 2004-03-25 2005-10-06 Canon Inc Communication method and communication apparatus
JP2008035374A (en) * 2006-07-31 2008-02-14 Canon Inc Server and method of controlling server
JP2008172407A (en) * 2007-01-10 2008-07-24 Toshiba Corp Portable communication terminal device

Family Cites Families (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6463418B1 (en) * 1997-08-15 2002-10-08 Sun Microsystems, Inc. Secure and stateful electronic business transaction system
US6397246B1 (en) * 1998-11-13 2002-05-28 International Business Machines Corporation Method and system for processing document requests in a network system
US6502106B1 (en) * 1999-03-25 2002-12-31 International Business Machines Corporation System, method, and program for accessing secondary storage in a network system
US6442601B1 (en) * 1999-03-25 2002-08-27 International Business Machines Corporation System, method and program for migrating files retrieved from over a network to secondary storage
US7003799B2 (en) * 2001-01-30 2006-02-21 Hewlett-Packard Development Company, L.P. Secure routable file upload/download across the internet
WO2003052610A1 (en) * 2001-12-13 2003-06-26 Thomson Licensing S.A. System and method for downloading data using a proxy
JP2004234380A (en) * 2003-01-30 2004-08-19 Fujitsu Ltd Table display switching method, text data conversion program, and tagging program
US20050138426A1 (en) * 2003-11-07 2005-06-23 Brian Styslinger Method, system, and apparatus for managing, monitoring, auditing, cataloging, scoring, and improving vulnerability assessment tests, as well as automating retesting efforts and elements of tests
US8010670B2 (en) * 2003-12-23 2011-08-30 Slipstream Data Inc. Meta-data based method for local cache utilization
US20060082807A1 (en) * 2004-09-17 2006-04-20 Tanaka Yokichi J Method and system for printing electronic mail
US7734292B2 (en) * 2005-12-07 2010-06-08 Electronics And Telecommunications Research Institute Terminal supporting peer-to-peer communication, and communication and billing methods based on the same
DE102008004690A1 (en) * 2008-01-16 2009-08-06 Fraunhofer-Gesellschaft zur Förderung der angewandten Forschung e.V. Forwarding node and terminal for an FDD communication network and method of operating the same
WO2010001593A1 (en) * 2008-07-04 2010-01-07 三洋電機株式会社 Wireless device and communication system
JP5369974B2 (en) 2009-08-04 2013-12-18 株式会社リコー Imaging apparatus and image sharing system
US20130094441A1 (en) * 2011-10-17 2013-04-18 Simon Milner System, method, device for wireless device association, program download, and exchange of data between wireless devices

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005277937A (en) * 2004-03-25 2005-10-06 Canon Inc Communication method and communication apparatus
JP2008035374A (en) * 2006-07-31 2008-02-14 Canon Inc Server and method of controlling server
JP2008172407A (en) * 2007-01-10 2008-07-24 Toshiba Corp Portable communication terminal device

Also Published As

Publication number Publication date
US9602579B2 (en) 2017-03-21
JP6271838B2 (en) 2018-01-31
US20140337415A1 (en) 2014-11-13
WO2014115612A1 (en) 2014-07-31

Similar Documents

Publication Publication Date Title
JP6141006B2 (en) Communication device, control method, and program
EP2991435B1 (en) Communication apparatus and control method of communication apparatus
JP2004112225A (en) Information communication system
JP6271843B2 (en) COMMUNICATION DEVICE, ITS CONTROL METHOD, PROGRAM
JP6242051B2 (en) COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
JP2015023440A (en) Communication device, communication method, and program
JP6214159B2 (en) COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
JP6173011B2 (en) COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
JP6312369B2 (en) COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
JP6271839B2 (en) COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
JP6271838B2 (en) COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
JP6271840B2 (en) COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
JP2014160319A (en) Communication apparatus, method for controlling communication apparatus, and program
JP2013157809A (en) Communication device, method for controlling the same, and program
JP6157190B2 (en) COMMUNICATION DEVICE, ITS CONTROL METHOD, PROGRAM
JP2014203201A (en) Communication device, and control method and program of the same
JP6207215B2 (en) COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
JP2020088712A (en) Communication device and control method thereof
JP6512798B2 (en) Communication apparatus, control method, and program
JP2015097383A (en) Communication device, control method for communication device, and program
JP6308719B2 (en) COMMUNICATION DEVICE, ITS CONTROL METHOD, PROGRAM
JP6489804B2 (en) COMMUNICATION DEVICE, COMMUNICATION DEVICE CONTROL METHOD, PROGRAM
JP5963438B2 (en) Device, communication control method thereof, and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20160125

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20170321

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20170518

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20171205

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20171228

R151 Written notification of patent or utility model registration

Ref document number: 6271838

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151