WO2015070540A1 - 一种终端的配对方法、终端及*** - Google Patents

一种终端的配对方法、终端及*** Download PDF

Info

Publication number
WO2015070540A1
WO2015070540A1 PCT/CN2014/071343 CN2014071343W WO2015070540A1 WO 2015070540 A1 WO2015070540 A1 WO 2015070540A1 CN 2014071343 W CN2014071343 W CN 2014071343W WO 2015070540 A1 WO2015070540 A1 WO 2015070540A1
Authority
WO
WIPO (PCT)
Prior art keywords
terminal
identity information
pairing
data packet
code
Prior art date
Application number
PCT/CN2014/071343
Other languages
English (en)
French (fr)
Inventor
李学平
李彬
王晓晖
Original Assignee
深圳创维数字技术股份有限公司
深圳市创维软件有限公司
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 深圳创维数字技术股份有限公司, 深圳市创维软件有限公司 filed Critical 深圳创维数字技术股份有限公司
Priority to EP14814728.3A priority Critical patent/EP2899956A4/en
Priority to US14/413,325 priority patent/US20150289301A1/en
Publication of WO2015070540A1 publication Critical patent/WO2015070540A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/11Allocation or use of connection identifiers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/50Secure pairing of devices
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M2250/00Details of telephonic subscriber devices
    • H04M2250/52Details of telephonic subscriber devices including functional features of a camera
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/60Context-dependent security
    • H04W12/69Identity-dependent
    • H04W12/77Graphical identity
    • 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
    • H04W88/00Devices specially adapted for wireless communication networks, e.g. terminals, base stations or access point devices
    • H04W88/02Terminal devices

Definitions

  • Terminal pairing method terminal and system
  • the present invention relates to the field of communications technologies, and in particular, to a terminal pairing method, terminal, and system. Background technique
  • the user's demand for terminal operation is not limited to a single terminal. Therefore, many terminals have a pairing function, and the user can pair with the designated terminal through the mobile terminal and then perform the designated terminal through the mobile terminal. Control operation.
  • the mobile terminal needs to be paired with the designated terminal, the designated terminal needs to communicate with the mobile terminal multiple times to determine the service for the designated terminal, the communication between the two parties is frequent, and the pairing efficiency is low, which is disadvantageous for the designated terminal to serve the mobile terminal.
  • the embodiment of the invention provides a pairing method, terminal and system for a terminal.
  • the terminal can be quickly paired with the designated terminal using a QR code.
  • a first aspect of the embodiments of the present invention provides a method for pairing terminals, including:
  • a pairing request for carrying a data packet where the data packet includes identity information of the target terminal and identity information of the second terminal, where the identity information of the target terminal is by the second terminal Obtained by scanning the identity QR code of the target terminal;
  • the first terminal determines that the identity information of the target terminal is the identity information of the first terminal, the first terminal generates a paired two-dimensional code according to the data packet, so that the second terminal scans and Parsing the paired two-dimensional code;
  • the first terminal acquires a pairing end command sent by the second terminal to accept a control operation of the second terminal, where the pairing end command is generated by the second terminal according to the parsed paired two-dimensional code The corresponding pairing end command.
  • the determining, by the first terminal, that the identity information of the target terminal is the identity information of the first terminal includes:
  • the first terminal parses the data packet, and extracts an identity letter of the target terminal from the data packet Determining, by the first terminal, whether identity information of the target terminal is identity information of the first terminal;
  • the first terminal extracts the identity information of the second terminal from the data packet.
  • the generating, by the first terminal, the paired two-dimensional code according to the data packet includes:
  • the first terminal generates the paired two-dimensional code according to the identity information of the second terminal, the identity information of the first terminal, and the pairing result information.
  • the first terminal generates the pairing according to the identity information of the second terminal, the identity information of the first terminal, and the pairing result information.
  • the dimension code includes:
  • the first terminal saves the identity information of the second terminal, and generates the pairing according to the identity information of the second terminal, the identity information of the first terminal, and the pairing result information. QR code.
  • a second aspect of the embodiments of the present invention provides a terminal, including:
  • a receiving module configured to receive a pairing request for carrying a data packet sent by the second terminal, where the data packet includes identity information of the target terminal and identity information of the second terminal, where the identity information of the target terminal is The second terminal is obtained by scanning the identity QR code of the target terminal;
  • a generating module configured to generate a paired two-dimensional code according to the data packet, if the identity information of the target terminal is determined to be the identity information of the first terminal, so that the second terminal scans and parses the pairing two Dimension code
  • An operation module configured to acquire a pairing end command sent by the second terminal, to receive a control operation of the second terminal, where the pairing end command is generated by the second terminal according to the parsed paired two-dimensional code The corresponding pairing end command.
  • the generating module includes: a first extracting unit, configured to parse the data packet, and extract identity information of the target terminal from the data packet;
  • a first determining unit configured to determine whether identity information of the target terminal extracted by the first extracting unit is identity information of the first terminal
  • a second extracting unit configured to: when the determination result of the first determining unit is YES, extract identity information of the second terminal from the data packet.
  • the generating module further includes:
  • a generating unit configured to generate the paired two-dimensional code according to identity information of the second terminal, identity information of the first terminal, and pairing result information.
  • the generating unit includes:
  • a second determining subunit configured to determine, according to the identity information of the second terminal, whether the second terminal is legal
  • a third determining subunit configured to: when the determining result of the second determining subunit is YES, further determining whether the first terminal stores a record that has been paired with the second terminal;
  • a two-dimensional code generating sub-unit configured to: when the determination result of the third determining sub-unit is negative, save the identity information of the second terminal, and according to the identity information of the second terminal, the first The identity information of the terminal and the pairing result information generate the paired two-dimensional code.
  • a third aspect of the embodiments of the present invention provides a pairing system, including: a first terminal and a second terminal, where:
  • the first terminal is configured to receive a pairing request for carrying a data packet sent by the second terminal, where the data packet includes identity information of the target terminal and identity information of the second terminal, and identity information of the target terminal. Obtained by the second terminal by scanning the identity two-dimensional code of the target terminal, if the first terminal determines that the identity information of the target terminal is the identity information of the first terminal, according to the data Generating a paired two-dimensional code, so that the second terminal scans and parses the paired two-dimensional code, and acquires a pairing end command sent by the second terminal to accept a control operation of the second terminal, where the pairing End command is a correspondence generated by the second terminal according to the parsed paired two-dimensional code Pairing end command;
  • the second terminal is configured to obtain identity information of the first terminal by scanning an identity two-dimensional code of the first terminal, and send, to the first terminal, a pairing request that carries the data packet, where the data packet is And including the identity information of the first terminal and the identity information of the second terminal, scanning and parsing the paired two-dimensional code generated by the first terminal according to the data packet, and sending the identifier to the first terminal according to the parsing Pair the corresponding pairing end command generated by the QR code.
  • the first terminal is further configured to parse the data packet, extract identity information of the target terminal from the data packet, and determine the Whether the identity information of the target terminal is the identity information of the first terminal, and if the determination is yes, extracting the identity information of the second terminal from the data packet, and according to the identity information of the second terminal, The identity information of the first terminal and the pairing result information generate the paired two-dimensional code.
  • the second terminal can obtain the identity information of the first terminal by scanning the identity two-dimensional code of the first terminal, and package the identity information of the first terminal and the identity information of the second terminal, and send the data packet to the second terminal.
  • the first terminal generates a paired two-dimensional code after the corresponding verification by the first terminal, so that the second terminal saves the data paired with the first terminal after scanning and parsing the paired two-dimensional code, and then sends the pairing end command to the first
  • a terminal prompts that the first terminal is paired, so that the first terminal and the second terminal can be quickly paired, the number of mutual communication is reduced, and the pairing efficiency is high.
  • FIG. 1 is a schematic flowchart of a pairing method of a terminal according to an embodiment of the present invention
  • FIG. 2 is a schematic flow chart of another method for pairing terminals according to an embodiment of the present invention.
  • FIG. 3 is a schematic structural diagram of a terminal according to an embodiment of the present invention.
  • FIG. 4 is a schematic structural diagram of a generation module of a terminal according to an embodiment of the present invention.
  • FIG. 5 is a schematic structural diagram of a generating unit of a generating module of a terminal according to an embodiment of the present invention
  • FIG. 6 is a schematic structural diagram of a pairing system according to an embodiment of the present invention.
  • the terminal can be quickly paired with the designated terminal by using the two-dimensional code.
  • FIG. 1 is a schematic flowchart diagram of a method for pairing terminals according to an embodiment of the present invention.
  • the first terminal in the embodiment of the present invention may be a networked terminal device, such as a smart television, a video player, a set top box, or the like, which is configured to generate a two-dimensional code.
  • the first terminal includes an interaction module and a background service module, and the interaction module is used. The information is received and sent, and the background service module is used to verify the information, generate a QR code, and the like.
  • the interaction module and the background service module may also be two independent devices, and the background service module and the second terminal perform pairing through information interaction of the interaction module.
  • the second terminal can be a networked mobile device that can recognize the two-dimensional code.
  • a pairing method of a terminal may include the following steps.
  • Step 100 The first terminal receives a pairing request for carrying a data packet sent by the second terminal, where the data packet includes identity information of the target terminal and identity information of the second terminal, and the identity information of the target terminal is used by the second terminal to scan the target terminal.
  • the identity QR code is obtained.
  • the second terminal when the second terminal is to be paired with the first terminal, the second terminal may scan the identity QR code that is displayed on the first terminal and can identify the first terminal, so as to obtain the identity information of the first terminal.
  • the second terminal may package the identity information of the first terminal and the identity information of the second terminal into a data packet according to a User Datagram Protocol (UDP), where the UDP protocol is an open system interconnection ( Open System Interconnect (OSI) A connectionless transport layer protocol in the reference model.
  • UDP User Datagram Protocol
  • OSI Open System Interconnect
  • the main function of the UDP protocol is to compress network data traffic into packets.
  • UDP is not a connection type protocol, so it has the advantages of low resource consumption and fast processing speed. Generally, audio, video, and normal data are transmitted using UDP protocols.
  • the second terminal sends the UDP data packet to the first terminal in the local area network through the Socket protocol, and the Socket protocol is also called a socket, and the application usually sends the connection to the network through the socket.
  • Socket is designed for client or server models, for Client and server programs provide different Socket system calls.
  • UDP sockets can be created by the Socket() function to send and receive information between different hosts via a socket descriptor.
  • the destination terminal box port that sends data can be specified when data is written, so that data can be sent to multiple terminals with one socket.
  • Step 110 If the first terminal determines that the identity information of the target terminal is the identity information of the first terminal, the first terminal generates a paired two-dimensional code according to the data packet, so that the second terminal scans and parses the paired two-dimensional code.
  • the first terminal after receiving the pairing request carrying the data packet, the first terminal unpacks the data packet, and determines the identity information of the target terminal. If the identity information of the target terminal is the identity information of the first terminal itself, the slave data The identity information of the second terminal is extracted from the packet, and the identity information of the second terminal is verified by the background service module to generate a paired two-dimensional code and displayed in the interaction module, and the second terminal may scan the pairing of the first terminal. The dimension code obtains the corresponding pairing data.
  • Step 120 The first terminal acquires a pairing end command sent by the second terminal to accept a control operation of the second terminal, where the pairing end command is a corresponding pairing end command generated by the second terminal according to the parsed paired two-dimensional code.
  • the second terminal after the second terminal obtains the corresponding pairing data by scanning the paired two-dimensional code of the first terminal, the data is saved to notify the user of the record that has been paired with the first terminal, and the corresponding data is generated according to the pairing data. Pairing end command. If the pairing end command is a pairing success command, the first terminal is reset after receiving, and begins to accept the control operation of the second terminal; if the pairing end command is a failure command, the first terminal receives the previously received data packet after discarding and recovers The original working status.
  • the second terminal can obtain the identity information of the first terminal by scanning the identity two-dimensional code of the first terminal, and package the identity information of the first terminal and the identity information of the second terminal according to the UDP protocol. Sending the data packet to the first terminal, and generating a paired two-dimensional code by the corresponding verification of the first terminal, so that the second terminal saves the data paired with the first terminal after scanning and parsing the paired two-dimensional code, and then The pairing end command is sent to the first terminal to prompt the end of the first terminal to be paired, so that the first terminal and the second terminal can be quickly paired, the number of mutual communication is reduced, and the pairing efficiency is high. Please refer to FIG. 2. FIG. 2. FIG.
  • the terminal may be a networked terminal device such as a smart TV, a video player, a set top box, etc., wherein the first terminal includes an interaction module and a background service module, and the interaction module is configured to receive and send information, and the background service module
  • the method is used for verifying information, generating a two-dimensional code, etc., as an implementable manner, the interaction module and the background service module may also be two independent networked smart devices, and the background service module interacts with the second terminal.
  • the information exchange of the modules is paired.
  • the embodiment of the present invention is described by using an interaction module and a background service module integrated in the first terminal.
  • the second terminal can be a networked mobile device that can recognize the two-dimensional code.
  • Step 200 The second terminal acquires identity information of the first terminal by scanning an identity two-dimensional code displayed by the interaction module of the first terminal.
  • the second terminal needs to have the function of identifying and parsing the two-dimensional code. Therefore, the second terminal can obtain the identity information of the first terminal by scanning the identity two-dimensional code displayed by the first terminal interaction module.
  • the identity second-dimensional code of the first terminal can be displayed not only through the interaction module, but also displayed on the outer casing of the first terminal by using various means such as printing, so that the user can find the first terminal more conveniently.
  • Identity information can be displayed not only through the interaction module, but also displayed on the outer casing of the first terminal by using various means such as printing, so that the user can find the first terminal more conveniently.
  • Step 201 The first terminal receives a pairing request for carrying a data packet sent by the second terminal.
  • the UDP protocol is used to package the data packet to use the Socket protocol to send the matching request carrying the data packet to the first terminal.
  • the second terminal sends a pairing request in the local area network, that is, not only the first terminal receives the pairing request sent by the second terminal, but the networked terminal in the local area network can receive the pairing sent by the second terminal. request.
  • Step 202 The first terminal parses the data packet, and extracts identity information of the target terminal from the data packet.
  • the interaction module of the first terminal receives the pairing request for carrying the data packet sent by the second terminal, the data packet is unpacked to obtain the identity information of the target terminal, that is, the terminal to be paired.
  • Step 203 The first terminal determines whether the identity information of the target terminal is identity information of the first terminal.
  • the interaction module of the first terminal determines the destination after obtaining the identity information of the target terminal. Whether the identity information of the target terminal is the identity information of the first terminal. If the determination is yes, step 204 is performed; if the determination is no, step 211 is performed.
  • Step 204 The first terminal extracts identity information of the second terminal from the data packet.
  • step 203 when the determining result of step 203 is YES, that is, the interaction module of the first terminal determines that the identity information of the target terminal in the data packet is the identity information of the first terminal, extracting the second terminal from the data packet Identity information, and the identity information of the second terminal is sent to the background service module.
  • Step 205 The first terminal determines, according to the identity information of the second terminal, whether the second terminal is legal.
  • the first terminal may establish a database in advance to store information of the terminal that can be paired. If a certain terminal can be paired with the first terminal, the terminal is legal to the first terminal.
  • the background service module of the first terminal receives the identity information of the second terminal sent by the interaction module, it is determined whether the second terminal can be paired with the first terminal. If the determination is yes, step 206 is performed; if the determination is no, Go to step 211.
  • Step 206 The first terminal further determines whether the first terminal stores the record that has been paired with the second terminal.
  • step 205 when the determination in step 205 is YES, the background service module of the first terminal continues to query whether the second terminal has paired with the first terminal. If the determination is yes, step 208 is performed; if the determination is no, Then step 207 is performed.
  • Step 207 The first terminal saves identity information of the second terminal.
  • the background service module of the first terminal saves the identity information of the second terminal, so that the paired two-dimensional code can be directly generated when the pairing request sent by the second terminal is re-received next time. , avoid repeating the above steps to improve the efficiency of pairing.
  • Step 208 The first terminal generates a paired two-dimensional code according to the identity information of the second terminal, the identity information of the first terminal, and the pairing result information.
  • the background service module of the first terminal when the determination result in step 206 is YES, or after performing step 207, the background service module of the first terminal generates a paired two-dimensional code according to the identity information of the second terminal, the identity information of the first terminal, and the pairing result information. And send the paired QR code to the interaction module for display in the interaction module.
  • the pairing result information is a related letter such as pairing success or pairing failure.
  • the pairing failed information is added when the paired two-dimensional code is generated to remind the second terminal that the pairing fails. If the first terminal can be successfully paired with the second terminal, the pairing success information is added when the paired two-dimensional code is generated.
  • Step 209 The second terminal scans the paired two-dimensional code displayed by the first terminal, parses the paired two-dimensional code, and saves the corresponding data.
  • the second terminal parses the paired two-dimensional code, information related to the content of the first terminal and the content of the control operation after the first terminal is paired is saved.
  • the second terminal can provide the user with information related to the first terminal or the operation of the first terminal.
  • Step 210 The first terminal acquires a pairing end command sent by the second terminal to accept a control operation of the second terminal.
  • the pairing end command is sent to the first terminal.
  • the pairing end command is a pairing success command
  • the first terminal resets after receiving the pairing success command, and starts accepting the control operation of the second terminal;
  • the information of the pairing includes the information of the pairing failure
  • the pairing end command is a pairing failure command.
  • the first terminal discards the previously received data packet and restores the original working state.
  • Step 211 The first terminal discards the data packet.
  • the first terminal discards the data packet.
  • this step is applicable to the unpaired terminal. Since the second terminal widely transmits the pairing request of the data packet in the local area network, each networked device in the local area network can receive the pairing sent by the second terminal.
  • the request for the terminal that does not need to be paired, judges whether the identity information of the target terminal matches the identity information of the target terminal according to the obtained data packet, and if it does not match, discards, restores the original working state, and does not need to perform further judgment verification, thereby improving The efficiency of pairing.
  • the second terminal can obtain the identity information of the first terminal by scanning the identity two-dimensional code of the first terminal, and package the identity information of the first terminal and the identity information of the second terminal according to the UDP protocol. And sending the data packet to the first terminal, after the corresponding verification of the first terminal Pairing the two-dimensional code, so that the second terminal saves the data paired with the first terminal after scanning and parsing the paired two-dimensional code, and then sends the pairing end command to the first terminal to prompt the first terminal to end the pairing, enabling A terminal and the second terminal are quickly paired to reduce the number of mutual communication, and the pairing efficiency is high.
  • FIG. 3 is a schematic structural diagram of a terminal according to an embodiment of the present invention.
  • a terminal shown in FIG. 3 includes: a receiving module 300, a generating module 310, and an operating module 320.
  • the receiving module 300 is configured to receive a pairing request for carrying a data packet sent by the second terminal, where the data packet includes identity information of the target terminal and identity information of the second terminal, where the identity information of the target terminal is used by the second terminal to scan the target terminal.
  • the identity QR code is obtained.
  • the generating module 310 is configured to: if the identity information of the target terminal is determined to be the identity information of the first terminal, generate a paired two-dimensional code according to the data packet, so that the second terminal scans and parses the paired two-dimensional code.
  • the operation module 320 is configured to obtain a pairing end command sent by the second terminal to accept a control operation of the second terminal, where the pairing end command is a corresponding pairing end command generated by the second terminal according to the parsed paired two-dimensional code.
  • FIG. 4 is a schematic structural diagram of a generation module of a terminal according to an embodiment of the present invention.
  • the generating module 310 shown in FIG. 4 includes: a first extracting unit 400, a first determining unit 410, a second extracting unit 420, and a generating unit 430.
  • the first extracting unit 400 is configured to parse the data packet, and extract identity information of the target terminal from the data packet.
  • the first determining unit 410 is configured to determine whether the identity information of the target terminal extracted by the first extracting unit 400 is the identity information of the first terminal.
  • the second extracting unit 420 is configured to: when the determination result of the first determining unit 410 is YES, the number of slaves The identity information of the second terminal is extracted according to the packet.
  • the generating unit 430 is configured to generate a paired two-dimensional code according to the identity information of the second terminal, the identity information of the first terminal, and the pairing result information.
  • FIG. 5 is a schematic structural diagram of a generating unit of a generating module of a terminal according to an embodiment of the present invention.
  • the generating unit 430 shown in FIG. 5 includes: a second judging subunit 500, a third judging subunit 510, and a two-dimensional code generating subunit 520.
  • the second determining subunit 500 is configured to determine, according to the identity information of the second terminal, whether the second terminal is legal.
  • the third determining sub-unit 510 is configured to: when the determination result of the second determining sub-unit 500 is YES, further determine whether the first terminal stores the record that has been paired with the second terminal.
  • the two-dimensional code generating sub-unit 520 is configured to: when the determination result of the third determining sub-unit 510 is negative, save the identity information of the second terminal, and according to the identity information of the second terminal, the identity information of the first terminal, and the pairing The resulting information generates a paired two-dimensional code.
  • FIG. 6 is a schematic structural diagram of a pairing system according to an embodiment of the present invention.
  • the system as shown in FIG. 6 includes: a first terminal 600 and a second terminal 610.
  • the first terminal 600 is configured to receive a pairing request for carrying a data packet sent by the second terminal 610, where the data packet includes identity information of the target terminal and identity information of the second terminal 610, and the identity information of the target terminal is adopted by the second terminal 610. Scanning the identity of the target terminal to obtain the QR code, if the first terminal If the identity information of the target terminal is determined to be the identity information of the first terminal 600, the paired two-dimensional code is generated according to the data packet, so that the second terminal 610 scans and parses the paired two-dimensional code, and acquires the pairing end command sent by the second terminal 610. To accept the control operation of the second terminal 610, the pairing end command is a corresponding pairing end command generated by the second terminal 610 according to the parsed paired two-dimensional code.
  • the second terminal 610 is configured to obtain identity information of the first terminal by scanning the identity two-dimensional code of the first terminal, and send a pairing request for carrying the data packet to the first terminal 600, where the data packet includes identity information of the first terminal and the second
  • the identity information of the terminal 610 scans and parses the paired two-dimensional code generated by the first terminal 600 according to the data packet, and transmits a corresponding pairing end command generated according to the parsed paired two-dimensional code to the first terminal 600.
  • the first terminal 600 is further configured to parse the data packet, extract the identity information of the target terminal from the data packet, and determine whether the identity information of the target terminal is the identity information of the first terminal 600, and if the determination is yes, Then, the identity information of the second terminal 610 is extracted from the data packet, and the paired two-dimensional code is generated according to the identity information of the second terminal 610, the identity information of the first terminal 600, and the pairing result information.
  • the second terminal can obtain the identity information of the first terminal by scanning the identity two-dimensional code of the first terminal, and package the identity information of the first terminal and the identity information of the second terminal and data.
  • the packet is sent to the first terminal, and the paired two-dimensional code is generated by the corresponding verification of the first terminal, so that the second terminal scans and parses the paired two-dimensional code, and sends the pairing end command to the first terminal to prompt the first terminal to end pairing.
  • the first terminal can be quickly paired with the second terminal, the number of mutual communication is reduced, and the pairing efficiency is high.
  • the device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separate, and the components displayed as units may or may not be physical units, ie may be located A place, or it can be distributed to multiple network units. Some or all of the modules may be selected according to actual needs to achieve the objectives of the solution of the embodiment. Those of ordinary skill in the art can understand and implement without deliberate labor.
  • Modules or units in the apparatus of the embodiments of the present invention may be combined, divided, and deleted according to actual needs.
  • the module or module of the embodiment of the present invention may be a general-purpose integrated circuit (such as a central processing unit CPU), or Implemented as an application specific integrated circuit (ASIC).
  • a general-purpose integrated circuit such as a central processing unit CPU
  • ASIC application specific integrated circuit

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

本发明实施例适用于通信技术领域,提供了一种终端的配对方法,包括:第一终端接收第二终端发送的携带数据包的配对请求,数据包包括目标终端的身份信息以及第二终端的身份信息,目标终端的身份信息是由第二终端通过扫描目标终端的身份二维码获得的;若第一终端确定目标终端的身份信息为第一终端的身份信息,则第一终端根据数据包生成配对二维码,以使第二终端扫描并解析配对二维码;第一终端获取第二终端发送的配对结束命令,以接受第二终端的控制操作,配对结束命令为第二终端根据解析后的配对二维码生成的对应的配对结束命令。本发明实施例还公开了一种终端及***。采用本发明,可利用二维码将终端与指定终端快速配对。

Description

一种终端的配对方法、 终端及***
技术领域
本发明涉及通信技术领域, 尤其涉及一种终端的配对方法、 终端及***。 背景技术
随着电子服务终端的功能越来越多元化,用户对于终端操作的需求不局限 于单个终端, 因此许多终端拥有配对功能, 用户可通过移动终端与指定终端互 相配对之后通过移动终端对指定终端进行控制操作。现有技术下, 当移动终端 需要与指定终端配对时,指定终端需要与移动终端进行多次的相互通信以确定 为指定终端服务, 双方通信频繁, 配对效率低下, 不利于指定终端为移动终端 服务。 发明内容
本发明实施例提供一种终端的配对方法、终端及***。可利用二维码将终 端与指定终端快速配对。
本发明实施例第一方面提供一种终端的配对方法, 包括:
第一终端接收第二终端发送的携带数据包的配对请求,所述数据包包括目 标终端的身份信息以及所述第二终端的身份信息,所述目标终端的身份信息是 由所述第二终端通过扫描所述目标终端的身份二维码获得的;
若所述第一终端确定所述目标终端的身份信息为所述第一终端的身份信 息, 则所述第一终端根据所述数据包生成配对二维码, 以使所述第二终端扫描 并解析所述配对二维码;
所述第一终端获取所述第二终端发送的配对结束命令,以接受所述第二终 端的控制操作,所述配对结束命令为所述第二终端根据所述解析后的配对二维 码生成的对应的配对结束命令。
在本发明实施例第一方面的第一种可能的实现方式中,所述若所述第一终 端确定所述目标终端的身份信息为所述第一终端的身份信息包括:
所述第一终端解析所述数据包,从所述数据包提取所述目标终端的身份信 所述第一终端判断所述目标终端的身份信息是否为所述第一终端的身份 信息;
若判断为是, 则所述第一终端从所述数据包提取所述第二终端的身份信 息。
在本发明实施例第一方面的第二种可能的实现方式中,所述第一终端根据 所述数据包生成配对二维码包括:
所述第一终端根据所述第二终端的身份信息、所述第一终端的身份信息以 及配对结果信息生成所述配对二维码。
在本发明实施例第一方面的第三种可能的实现方式中,所述第一终端根据 所述第二终端的身份信息、所述第一终端的身份信息以及配对结果信息生成所 述配对二维码包括:
所述第一终端根据所述第二终端的身份信息判断所述第二终端是否合法; 若判断为是,则所述第一终端进一步判断所述第一终端是否存储已与所述 第二终端配对的记录;
若判断为否, 则所述第一终端保存所述第二终端的身份信息, 并根据所述 第二终端的身份信息、所述第一终端的身份信息以及所述配对结果信息生成所 述配对二维码。
本发明实施例第二方面提供一种终端, 包括:
接收模块, 用于接收第二终端发送的携带数据包的配对请求, 所述数据包 包括目标终端的身份信息以及所述第二终端的身份信息,所述目标终端的身份 信息是由所述第二终端通过扫描所述目标终端的身份二维码获得的;
生成模块,用于若确定所述目标终端的身份信息为所述第一终端的身份信 息, 则根据所述数据包生成配对二维码, 以使所述第二终端扫描并解析所述配 对二维码;
操作模块, 用于获取所述第二终端发送的配对结束命令, 以接受所述第二 终端的控制操作,所述配对结束命令为所述第二终端根据所述解析后的配对二 维码生成的对应的配对结束命令。
在本发明实施例第二方面的第一种可能的实现方式中, 所述生成模块包 括: 第一提取单元, 用于解析所述数据包,从所述数据包提取所述目标终端的 身份信息;
第一判断单元,用于判断所述第一提取单元提取的目标终端的身份信息是 否为所述第一终端的身份信息;
第二提取单元, 用于当所述第一判断单元的判断结果为是时, 则从所述数 据包提取所述第二终端的身份信息。
在本发明实施例第二方面的第二种可能的实现方式中,所述生成模块还包 括:
生成单元, 用于根据所述第二终端的身份信息、所述第一终端的身份信息 以及配对结果信息生成所述配对二维码。
在本发明实施例第二方面的第三种可能的实现方式中, 所述生成单元包 括:
第二判断子单元,用于根据所述第二终端的身份信息判断所述第二终端是 否合法;
第三判断子单元, 用于当所述第二判断子单元的判断结果为是时, 则进一 步判断所述第一终端是否存储已与所述第二终端配对的记录;
二维码生成子单元, 用于当所述第三判断子单元的判断结果为否时, 则保 存所述第二终端的身份信息, 并根据所述第二终端的身份信息、所述第一终端 的身份信息以及所述配对结果信息生成所述配对二维码。
本发明实施例第三方面提供一种配对***,包括:第一终端以及第二终端, 其中:
所述第一终端, 用于接收所述第二终端发送的携带数据包的配对请求, 所 述数据包包括目标终端的身份信息以及所述第二终端的身份信息,所述目标终 端的身份信息是由所述第二终端通过扫描所述目标终端的身份二维码获得的, 若所述第一终端确定所述目标终端的身份信息为所述第一终端的身份信息,则 根据所述数据包生成配对二维码,以使所述第二终端扫描并解析所述配对二维 码,获取所述第二终端发送的配对结束命令,以接受所述第二终端的控制操作, 所述配对结束命令为所述第二终端根据所述解析后的配对二维码生成的对应 的配对结束命令;
所述第二终端,用于通过扫描所述第一终端的身份二维码获得所述第一终 端的身份信息, 向所述第一终端发送携带所述数据包的配对请求, 所述数据包 包括所述第一终端的身份信息以及所述第二终端的身份信息,扫描并解析所述 第一终端根据所述数据包生成的配对二维码,向所述第一终端发送根据解析后 的配对二维码生成的对应的配对结束命令。
在本发明实施例第三方面的第一种可能的实现方式中, 所述第一终端,还 用于解析所述数据包,从所述数据包提取所述目标终端的身份信息, 判断所述 目标终端的身份信息是否为所述第一终端的身份信息,若判断为是, 则从所述 数据包提取所述第二终端的身份信息, 并根据所述第二终端的身份信息、所述 第一终端的身份信息以及配对结果信息生成所述配对二维码。
采用本发明实施例,能使第二终端通过扫描第一终端的身份二维码得到第 一终端的身份信息,将第一终端的身份信息与第二终端的身份信息打包并将数 据包发送至第一终端,通过第一终端的相应验证后生成配对二维码, 以使第二 终端通过扫描并解析配对二维码之后保存与第一终端完成配对的数据,再将配 对结束命令发送给第一终端提示第一终端配对结束,能使第一终端与第二终端 快速配对, 减少相互通信次数, 配对效率高。 附图说明
为了更清楚地说明本发明实施例的技术方案,下面将对实施例描述中所需 要使用的附图作简单地介绍,显而易见地, 下面描述中的附图是本发明的一些 实施例, 对于本领域普通技术人员来讲, 在不付出创造性劳动性的前提下, 还 可以根据这些附图获得其他的附图。
图 1是本发明实施例的一种终端的配对方法的流程示意图;
图 2是本发明实施例的另一种终端的配对方法的流程示意图;
图 3是本发明实施例的一种终端的结构示意图;
图 4是本发明实施例的一种终端的生成模块的结构示意图;
图 5是本发明实施例的一种终端的生成模块的生成单元的结构示意图; 图 6是本发明实施例的一种配对***的结构示意图。 具体实施方式
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清 楚、 完整地描述, 显然, 所描述的实施例是本发明一部分实施例, 而不是全部 的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳 动前提下所获得的所有其他实施例, 都属于本发明保护的范围。
采用本发明实施例, 可利用二维码将终端与指定终端快速配对。
请参阅图 1 , 图 1是本发明实施例的一种终端的配对方法的流程示意图。 本发明实施例所涉及的第一终端可以为具备生成二维码功能的智能电视机、影 音播放器、 机顶盒等联网终端设备, 其中, 第一终端包括交互模块以及后台服 务模块,交互模块用于接收并发送信息,而后台服务模块则用于对信息的验证、 生成二维码等。作为一种可实施的方式, 交互模块与后台服务模块还可以为两 个独立的设备,并由后台服务模块与第二终端通过交互模块的信息交互进行配 对。 第二终端可以为能识别二维码的联网移动设备。
如图 1所示, 本发明实施例的一种终端的配对方法可以包括以下步骤。 步骤 100, 第一终端接收第二终端发送的携带数据包的配对请求, 数据包 包括目标终端的身份信息以及第二终端的身份信息, 目标终端的身份信息是由 第二终端通过扫描目标终端的身份二维码获得的。
具体实现中, 当第二终端欲与第一终端进行配对时, 第二终端可扫描对第 一终端展示的能标识第一终端的身份二维码, 从而获取到第一终端的身份信 息。
作为一种可实施的方式,第二终端可将第一终端的身份信息与第二终端的 身份信息根据用户数据包协议 ( User Datagram Protocol, UDP )打包成数据包, UDP协议是开放***互联( Open System Interconnect, OSI )参考模型中的一种 无连接的传输层协议, UDP协议的主要作用是将网络数据流量压缩成数据包 的形式。 UDP不属于连接型协议, 因而具有资源消耗小, 处理速度快的优点, 通常音频、 视频和普通数据在传送时使用 UDP协议较多。 打包完成之后, 第 二终端将 UDP数据包在局域网内通过 Socket协议将携带数据包的配对请求发 送给第一终端, Socket协议为也称作套接字,应用程序通常通过套接字向网络 发出请求或者应答网络请求。 Socket是面向客户或服务器模型而设计的,针对 客户和服务器程序提供不同的 Socket***调用。 UDP套接字可通过 Socket() 函数创建,通过一个套接字描述符在不同的主机之间发送和接收信息。发送数 据的目标终端盒端口可以在数据写入时指定,这样就可以用一个套接字发送数 据到多个终端。
步骤 110, 若第一终端确定目标终端的身份信息为第一终端的身份信息, 则第一终端根据数据包生成配对二维码, 以使第二终端扫描并解析配对二维 码。
具体实现中,第一终端接收到携带数据包的配对请求之后,将数据包拆包, 对目标终端的身份信息进行判定,若目标终端的身份信息为第一终端自身的身 份信息, 则从数据包中提取第二终端的身份信息,通过后台服务模块对第二终 端的身份信息进行相应的验证之后生成配对二维码并于交互模块进行展示,第 二终端则可扫描第一终端的配对二维码获得相应的配对数据。
步骤 120, 第一终端获取第二终端发送的配对结束命令, 以接受第二终端 的控制操作,配对结束命令为第二终端根据解析后的配对二维码生成的对应的 配对结束命令。
具体实现中,当第二终端通过扫描第一终端的配对二维码获得相应的配对 数据之后,保存数据以便下次配对时告知用户已与第一终端配对的记录, 并根 据配对数据生成对应的配对结束命令。若配对结束命令为配对成功命令, 则第 一终端接收之后复位, 开始接受第二终端的控制操作; 若配对结束命令为失败 命令, 则第一终端接收之后将之前接收的数据包丟弃, 恢复原先的工作状态。
通过实施图 1所描述的方法,能使第二终端通过扫描第一终端的身份二维 码得到第一终端的身份信息,将第一终端的身份信息与第二终端的身份信息根 据 UDP协议打包并将数据包发送至第一终端, 通过第一终端的相应验证后生 成配对二维码,以使第二终端通过扫描并解析配对二维码之后保存与第一终端 完成配对的数据, 再将配对结束命令发送给第一终端提示第一终端配对结束, 能使第一终端与第二终端快速配对, 减少相互通信次数, 配对效率高。 请参阅图 2,图 2是本发明实施例的另一种终端的配对方法的流程示意图。 图 2是在实施例图 1的基础上进行进一步的拓展,本发明实施例所涉及的第一 终端可以为具备生成二维码功能的智能电视机、影音播放器、机顶盒等联网终 端设备, 其中, 第一终端包括交互模块以及后台服务模块, 交互模块用于接收 并发送信息, 而后台服务模块则用于对信息的验证、 生成二维码等, 作为一种 可实施的方式, 交互模块与后台服务模块还可以为两个独立的联网智能设备, 并由后台服务模块与第二终端通过交互模块的信息交互进行配对。本发明实施 例则以交互模块与后台服务模块集成于第一终端进行举例说明。第二终端可以 为能识别二维码的联网移动设备。
如图 2所示, 本发明实施例的另一种终端的配对方法可以包括以下步骤。 步骤 200, 第二终端通过扫描第一终端的交互模块展示的身份二维码获取 第一终端的身份信息。
具体实现中, 第二终端需要具备识别并解析二维码的功能, 因此第二终端 通过扫描第一终端交互模块展示的身份二维码之后即可获得第一终端的身份 信息。
作为一种可实施的方式,第一终端的身份二维码不仅可以通过交互模块展 示,还可以通过印刷等多种方式在第一终端的外壳上展示, 以使用户更方便得 找到第一终端的身份信息。
步骤 201 , 第一终端接收第二终端发送的携带数据包的配对请求。
具体实现中, 当第二终端获取到第一终端的身份信息之后,加上第二终端 的身份信息, 通过 UDP协议打包成数据包利用 Socket协议将携带数据包的配 对请求发送给第一终端。
作为一种可实施的方式, 第二终端在局域网中广发配对请求, 即, 不仅第 一终端会接收到第二终端发送的配对请求,局域网内的联网终端都能接收到第 二终端发送的配对请求。
步骤 202, 第一终端解析数据包, 从数据包提取目标终端的身份信息。 具体实现中,当第一终端的交互模块接收到第二终端发送的携带数据包的 配对请求之后, 将数据包拆包, 获得目标终端亦即欲配对终端的身份信息。
步骤 203 , 第一终端判断目标终端的身份信息是否为第一终端的身份信 息。
具体实现中,第一终端的交互模块在获得目标终端的身份信息之后判断目 标终端的身份信息是否为第一终端的身份信息。若判断为是,则执行步骤 204; 若判断为否, 则执行步骤 211。
步骤 204, 第一终端从数据包提取第二终端的身份信息。
具体实现中, 当步骤 203的判断结果为是时, 即第一终端的交互模块判断 出数据包中的目标终端的身份信息为第一终端的身份信息,则从数据包中提取 第二终端的身份信息, 并将第二终端的身份信息发送给后台服务模块。
步骤 205 , 第一终端根据第二终端的身份信息判断第二终端是否合法。 作为一种可实施的方式, 第一终端可事先建立数据库,存储能配对的终端 的信息,若某种终端能与第一终端配对,说明这种终端对于第一终端是合法的。 当第一终端的后台服务模块接收到交互模块发送的第二终端的身份信息后,判 断第二终端是否能与第一终端配对, 若判断为是, 则执行步骤 206; 若判断为 否, 则执行步骤 211。
步骤 206, 第一终端进一步判断第一终端是否存储已与第二终端配对的记 录。
具体实现中, 当步骤 205的判断为是时, 则第一终端的后台服务模块继续 查询第二终端是否与第一终端做过配对, 若判断为是, 则执行步骤 208; 若判 断为否, 则执行步骤 207。
步骤 207, 第一终端保存第二终端的身份信息。
具体实现中, 当步骤 206的判断结果为否时, 则第一终端的后台服务模块 保存第二终端的身份信息以便下次重新接收到第二终端发送的配对请求时能 直接生成配对二维码, 避免重复上述步骤, 提高配对效率。
步骤 208, 第一终端根据第二终端的身份信息、 第一终端的身份信息以及 配对结果信息生成配对二维码。
具体实现中, 当步骤 206的判断结果为是时, 或者执行步骤 207之后, 第 一终端的后台服务模块根据第二终端的身份信息、第一终端的身份信息以及配 对结果信息生成配对二维码, 并将配对二维码发送至交互模块, 于交互模块进 行展示。
作为一种可实施的方式,配对结果信息为配对成功或者配对失败等相关信 ir 作为一种可实施的方式,若第一终端在配对过程中出现故障则在生成配对 二维码时加入配对失败的信息以提醒第二终端配对失败。若第一终端能与第二 终端顺利配对, 则在生成配对二维码时加入配对成功的信息。
步骤 209, 第二终端扫描第一终端显示的配对二维码, 解析配对二维码并 保存相应数据。
具体实现中, 第二终端解析配对二维码之后,保存第一终端的身份信息与 第一终端配对后实现控制操作的内容等相关信息。以使用户下次需要将第二终 端与第一终端进行配对时第二终端能够给用户提供与第一终端做过配对、或者 对第一终端进行操作的记录等相关资讯。
步骤 210, 第一终端获取第二终端发送的配对结束命令, 以接受第二终端 的控制操作。
具体实现中, 当第二终端解析配对二维码得到配对成功与否的信息之后, 向第一终端发送配对结束命令。
作为一种可实施的方式,若解析出的信息里包括配对成功的信息, 则配对 结束命令为配对成功命令, 第一终端接收配对成功命令之后复位, 开始接受第 二终端的控制操作; 若解析出的信息里包括配对失败的信息, 则配对结束命令 为配对失败命令, 第一终端接收配对失败命令之后将之前接收的数据包丟弃, 恢复原先的工作状态。
步骤 211 , 第一终端丟弃数据包。
具体实现中, 当步骤 203的判断结果为否时, 或者步骤 205的判断结果为 否时, 则第一终端丟弃数据包。
作为一种可实施的方式,此步骤适用于非配对的终端, 由于第二终端在局 域网内广发携带数据包的配对请求,在局域网内的每一个联网设备都能接收到 第二终端发送的配对请求,对于不需要配对的终端,根据获取到的数据包判断 目标终端的身份信息是否与自身的身份信息相符, 若不符即丟弃, 恢复原先工 作状态, 无需再进行进一步的判断验证, 提高了配对的效率。
通过实施图 2所描述的方法,能使第二终端通过扫描第一终端的身份二维 码得到第一终端的身份信息,将第一终端的身份信息与第二终端的身份信息根 据 UDP协议打包并将数据包发送至第一终端, 通过第一终端的相应验证后生 成配对二维码,以使第二终端通过扫描并解析配对二维码之后保存与第一终端 完成配对的数据, 再将配对结束命令发送给第一终端提示第一终端配对结束, 能使第一终端与第二终端快速配对, 减少相互通信次数, 配对效率高。 请参阅图 3 , 图 3是本发明实施例的一种终端的结构示意图。 如图 3所示 的一种终端包括: 接收模块 300、 生成模块 310以及操作模块 320。 接收模块 300, 用于接收第二终端发送的携带数据包的配对请求, 数据包 包括目标终端的身份信息以及第二终端的身份信息, 目标终端的身份信息是由 第二终端通过扫描目标终端的身份二维码获得的。
生成模块 310, 用于若确定目标终端的身份信息为第一终端的身份信息, 则根据数据包生成配对二维码, 以使第二终端扫描并解析配对二维码。
操作模块 320, 用于获取第二终端发送的配对结束命令, 以接受第二终端 的控制操作,配对结束命令为第二终端根据解析后的配对二维码生成的对应的 配对结束命令。
通过实施图 3所描述的终端,能使第二终端通过扫描第一终端的身份二维 码得到第一终端的身份信息,将第一终端的身份信息与第二终端的身份信息打 包并将数据包发送至第一终端, 通过第一终端的相应验证后生成配对二维码, 以使第二终端通过扫描并解析配对二维码之后生成配对结束命令发送给第一 终端提示第一终端配对结束, 能使第一终端与第二终端快速配对, 减少相互通 信次数, 配对效率高。 请参阅图 4, 图 4是本发明实施例的一种终端的生成模块的结构示意图。 如图 4所示的生成模块 310包括: 第一提取单元 400、 第一判断单元 410、 第 二提取单元 420以及生成单元 430。
第一提取单元 400,用于解析数据包,从数据包提取目标终端的身份信息。 第一判断单元 410, 用于判断第一提取单元 400提取的目标终端的身份信 息是否为第一终端的身份信息。
第二提取单元 420, 用于当第一判断单元 410的判断结果为是时, 则从数 据包提取第二终端的身份信息。
生成单元 430, 用于根据第二终端的身份信息、 第一终端的身份信息以及 配对结果信息生成配对二维码。
通过实施图 4所描述的生成模块, 能使第一终端与第二终端进行一对一配 对, 当其他终端不需要与第二终端配对却同时接收到数据包时,根据目标终端 的身份信息即可判断是否需要与第二终端配对, 当判断为是时, 第一终端则从 接收的数据包中提取第二终端的身份信息,并根据第一终端的身份信息以及配 对结果信息生成配对二维码, 过程方便简洁效率高。 请参阅图 5 ,图 5是本发明实施例的一种终端的生成模块的生成单元的结构 示意图。 如图 5所示的生成单元 430包括: 第二判断子单元 500、 第三判断子单 元 510以及二维码生成子单元 520。
第二判断子单元 500, 用于根据第二终端的身份信息判断第二终端是否合 法。
第三判断子单元 510, 用于当第二判断子单元 500的判断结果为是时, 则 进一步判断第一终端是否存储已与第二终端配对的记录。
二维码生成子单元 520, 用于当第三判断子单元 510的判断结果为否时, 则保存第二终端的身份信息, 并根据第二终端的身份信息、第一终端的身份信 息以及配对结果信息生成配对二维码。
通过实施图 5所描述的生成单元,能使第一终端对第二终端进行相应的验 证, 若第一终端与第二终端没有做过配对则配对后保存配对记录, 以便下次第 二终端与第一终端配对时省略相应的验证步骤, 提高配对效率。 请参阅图 6, 图 6是本发明实施例的一种配对***的结构示意图。 如图 6所 示的***包括: 第一终端 600以及第二终端 610。
第一终端 600, 用于接收第二终端 610发送的携带数据包的配对请求, 数 据包包括目标终端的身份信息以及第二终端 610的身份信息, 目标终端的身份 信息是由第二终端 610通过扫描目标终端的身份二维码获得的, 若第一终端 600确定目标终端的身份信息为第一终端 600的身份信息, 则根据数据包生成 配对二维码, 以使第二终端 610 扫描并解析配对二维码, 获取第二终端 610 发送的配对结束命令, 以接受第二终端 610的控制操作, 配对结束命令为第二 终端 610根据解析后的配对二维码生成的对应的配对结束命令。
第二终端 610, 用于通过扫描第一终端的身份二维码获得第一终端的身份 信息, 向第一终端 600发送携带数据包的配对请求,数据包包括第一终端的身 份信息以及第二终端 610的身份信息,扫描并解析第一终端 600根据数据包生 成的配对二维码,向第一终端 600发送根据解析后的配对二维码生成的对应的 配对结束命令。
作为一种可实施的方式, 第一终端 600还用于解析数据包,从数据包提取 目标终端的身份信息,判断目标终端的身份信息是否为第一终端 600的身份信 息, 若判断为是, 则从数据包提取第二终端 610的身份信息, 并根据第二终端 610的身份信息、第一终端 600的身份信息以及配对结果信息生成配对二维码。
通过实施图 6所描述的***,能使第二终端通过扫描第一终端的身份二维 码得到第一终端的身份信息,将第一终端的身份信息与第二终端的身份信息打 包并将数据包发送至第一终端,通过第一终端的相应验证后生成配对二维码以 使第二终端通过扫描并解析配对二维码,将配对结束命令发送给第一终端提示 第一终端配对结束, 能使第一终端与第二终端快速配对, 减少相互通信次数, 配对效率高。
以上所描述的装置实施例仅仅是示意性的,其中所述作为分离部件说明的 单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也 可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。 可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目 的。本领域普通技术人员在不付出创造性的劳动的情况下,即可以理解并实施。
本发明实施例方法中的步骤可以根据实际需要进行顺序调整、 合并和删 减。
本发明实施例装置中的模块或单元可以根据实际需要进行合并、划分和删 减。
本发明实施例的模块或模块,可以以通用集成电路 (如中央处理器 CPU),或 以专用集成电路 (ASIC)来实现。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到各实施 方式可借助软件加必需的通用硬件平台的方式来实现, 当然也可以通过硬件。 基于这样的理解,上述技术方案本质上或者说对现有技术做出贡献的部分可以 以软件产品的形式体现出来,该计算机软件产品可以存储在计算机可读存储介 质中, 如 ROM/RAM、 磁碟、 光盘等, 包括若干指令用以使得一台计算机终端 (可以是个人计算机, 服务器, 或者网络终端等)执行各个实施例或者实施例 的某些部分所述的方法。
以上所述的实施方式, 并不构成对该技术方案保护范围的限定。任何在上 述实施方式的精神和原则之内所作的修改、等同替换和改进等, 均应包含在该 技术方案的保护范围之内。

Claims

权 利 要 求
1、 一种终端的配对方法, 其特征在于, 包括:
第一终端接收第二终端发送的携带数据包的配对请求,所述数据包包括目 标终端的身份信息以及所述第二终端的身份信息,所述目标终端的身份信息是 由所述第二终端通过扫描所述目标终端的身份二维码获得的;
若所述第一终端确定所述目标终端的身份信息为所述第一终端的身份信 息, 则所述第一终端根据所述数据包生成配对二维码, 以使所述第二终端扫描 并解析所述配对二维码;
所述第一终端获取所述第二终端发送的配对结束命令,以接受所述第二终 端的控制操作,所述配对结束命令为所述第二终端根据所述解析后的配对二维 码生成的对应的配对结束命令。
2、 根据权利要求 1所述的方法, 其特征在于, 所述若所述第一终端确定 所述目标终端的身份信息为所述第一终端的身份信息包括:
所述第一终端解析所述数据包,从所述数据包提取所述目标终端的身份信 所述第一终端判断所述目标终端的身份信息是否为所述第一终端的身份 信息;
若判断为是, 则所述第一终端从所述数据包提取所述第二终端的身份信 息。
3、 根据权利要求 2所述的方法, 其特征在于, 所述第一终端根据所述数 据包生成配对二维码包括:
所述第一终端根据所述第二终端的身份信息、所述第一终端的身份信息以 及配对结果信息生成所述配对二维码。
4、 根据权利要求 3所述的方法, 其特征在于, 所述第一终端根据所述第 二终端的身份信息、所述第一终端的身份信息以及配对结果信息生成所述配对 二维码包括:
所述第一终端根据所述第二终端的身份信息判断所述第二终端是否合法; 若判断为是,则所述第一终端进一步判断所述第一终端是否存储已与所述 第二终端配对的记录;
若判断为否, 则所述第一终端保存所述第二终端的身份信息, 并根据所述 第二终端的身份信息、所述第一终端的身份信息以及所述配对结果信息生成所 述配对二维码。
5、 一种终端, 其特征在于, 包括:
接收模块, 用于接收第二终端发送的携带数据包的配对请求, 所述数据包 包括目标终端的身份信息以及所述第二终端的身份信息,所述目标终端的身份 信息是由所述第二终端通过扫描所述目标终端的身份二维码获得的;
生成模块,用于若确定所述目标终端的身份信息为所述第一终端的身份信 息, 则根据所述数据包生成配对二维码, 以使所述第二终端扫描并解析所述配 对二维码;
操作模块, 用于获取所述第二终端发送的配对结束命令, 以接受所述第二 终端的控制操作,所述配对结束命令为所述第二终端根据所述解析后的配对二 维码生成的对应的配对结束命令。
6、 根据权利要求 5所述的终端, 其特征在于, 所述生成模块包括: 第一提取单元, 用于解析所述数据包,从所述数据包提取所述目标终端的 身份信息;
第一判断单元,用于判断所述第一提取单元提取的目标终端的身份信息是 否为所述第一终端的身份信息;
第二提取单元, 用于当所述第一判断单元的判断结果为是时, 则从所述数 据包提取所述第二终端的身份信息。
7、 根据权利要求 6所述的终端, 其特征在于, 所述生成模块还包括: 生成单元,用于根据所述第二终端的身份信息、所述第一终端的身份信息 以及配对结果信息生成所述配对二维码。
8、 根据权利要求 7所述的终端, 其特征在于, 所述生成单元包括: 第二判断子单元,用于根据所述第二终端的身份信息判断所述第二终端是 否合法;
第三判断子单元, 用于当所述第二判断子单元的判断结果为是时, 则进一 步判断所述第一终端是否存储已与所述第二终端配对的记录;
二维码生成子单元, 用于当所述第三判断子单元的判断结果为否时, 则保 存所述第二终端的身份信息, 并根据所述第二终端的身份信息、所述第一终端 的身份信息以及所述配对结果信息生成所述配对二维码。
9、 一种配对***, 其特征在于, 包括: 第一终端以及第二终端, 其中: 所述第一终端, 用于接收所述第二终端发送的携带数据包的配对请求, 所 述数据包包括目标终端的身份信息以及所述第二终端的身份信息,所述目标终 端的身份信息是由所述第二终端通过扫描所述目标终端的身份二维码获得的, 若所述第一终端确定所述目标终端的身份信息为所述第一终端的身份信息,则 根据所述数据包生成配对二维码,以使所述第二终端扫描并解析所述配对二维 码,获取所述第二终端发送的配对结束命令,以接受所述第二终端的控制操作, 所述配对结束命令为所述第二终端根据所述解析后的配对二维码生成的对应 的配对结束命令;
所述第二终端,用于通过扫描所述第一终端的身份二维码获得所述第一终 端的身份信息, 向所述第一终端发送携带所述数据包的配对请求, 所述数据包 包括所述第一终端的身份信息以及所述第二终端的身份信息,扫描并解析所述 第一终端根据所述数据包生成的配对二维码,向所述第一终端发送根据解析后 的配对二维码生成的对应的配对结束命令。
10、 根据权利要求 9所述的***, 其特征在于,
所述第一终端,还用于解析所述数据包,从所述数据包提取所述目标终端 的身份信息, 判断所述目标终端的身份信息是否为所述第一终端的身份信息, 若判断为是, 则从所述数据包提取所述第二终端的身份信息, 并根据所述第二 终端的身份信息、所述第一终端的身份信息以及配对结果信息生成所述配对二 维码。
PCT/CN2014/071343 2013-11-14 2014-01-24 一种终端的配对方法、终端及*** WO2015070540A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP14814728.3A EP2899956A4 (en) 2013-11-14 2014-01-24 METHOD FOR COMPENSATION OF DEVICES, END UNIT AND SYSTEM
US14/413,325 US20150289301A1 (en) 2013-11-14 2014-01-24 Terminal matching method, terminal and system

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201310568068.5A CN103647869B (zh) 2013-11-14 2013-11-14 一种终端的配对方法、终端及***
CN201310568068.5 2013-11-14

Publications (1)

Publication Number Publication Date
WO2015070540A1 true WO2015070540A1 (zh) 2015-05-21

Family

ID=50253022

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2014/071343 WO2015070540A1 (zh) 2013-11-14 2014-01-24 一种终端的配对方法、终端及***

Country Status (4)

Country Link
US (1) US20150289301A1 (zh)
EP (1) EP2899956A4 (zh)
CN (1) CN103647869B (zh)
WO (1) WO2015070540A1 (zh)

Families Citing this family (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104915607B (zh) * 2015-04-28 2018-02-09 武汉理工大学 一种基于移动终端的密码数据处理和交换方法
CN106330825A (zh) * 2015-06-24 2017-01-11 中兴通讯股份有限公司 资源信息推送方法及装置
CN105187481A (zh) * 2015-07-11 2015-12-23 深圳市美贝壳科技有限公司 两个终端之间数据分享方法
CN105116883A (zh) * 2015-07-14 2015-12-02 上海智臻智能网络科技股份有限公司 建立扫地机器人与终端对应关系的方法、服务器及***
CN104966015B (zh) * 2015-07-30 2018-01-19 成都中科创达软件有限公司 一种智能设备之间的控制方法及***
CN105828274A (zh) * 2015-09-18 2016-08-03 维沃移动通信有限公司 一种终端的连接方法、第一终端及第二终端
CN107113701A (zh) * 2015-11-03 2017-08-29 国民技术股份有限公司 一种配对方法、配对装置以及智能终端和智能卡
CN110851270A (zh) * 2019-10-21 2020-02-28 ***股份有限公司 资源转移方法、装置、设备及介质
CN112104911B (zh) * 2020-09-21 2023-02-03 深圳创维-Rgb电子有限公司 数据检测方法、电视终端及***
CN112492050A (zh) * 2020-12-16 2021-03-12 赵全 一种终端间数据传输的方法及***
CN113359526A (zh) * 2021-06-10 2021-09-07 上海钛米机器人股份有限公司 权限数据处理方法、装置、设备及存储介质
CN114489009A (zh) * 2022-01-24 2022-05-13 深圳市元征科技股份有限公司 配置信息的写入方法、装置、电子设备及存储介质

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102185884A (zh) * 2011-03-18 2011-09-14 北京易视腾科技有限公司 多屏互动方法及***
CN103051694A (zh) * 2012-12-12 2013-04-17 北京奇虎科技有限公司 移动通信终端控制设备的方法与移动通信终端
CN103369035A (zh) * 2013-06-24 2013-10-23 四川长虹电器股份有限公司 基于二维码的智能家电通讯方法

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5235642A (en) * 1992-07-21 1993-08-10 Digital Equipment Corporation Access control subsystem and method for distributed computer system using locally cached authentication credentials
CA2408233C (en) * 2000-05-05 2007-01-09 Nomadix,Inc. Network usage monitoring device and associated method
JP2007104137A (ja) * 2005-09-30 2007-04-19 Matsushita Electric Ind Co Ltd データ通信装置
FR2906667B1 (fr) * 2006-10-02 2009-01-16 Eastman Kodak Co Production de codes visuels pour l'appariement d'equipements electroniques.
CN101855861A (zh) * 2007-11-16 2010-10-06 富士通天株式会社 认证方法、认证***、车载装置以及认证装置
US8572375B2 (en) * 2009-09-23 2013-10-29 Microsoft Corporation Device pairing based on graphically encoded data
US8823494B1 (en) * 2010-11-19 2014-09-02 Logitech Europe S.A. Systems and methods for wireless device connection and pairing
US9143402B2 (en) * 2012-02-24 2015-09-22 Qualcomm Incorporated Sensor based configuration and control of network devices

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102185884A (zh) * 2011-03-18 2011-09-14 北京易视腾科技有限公司 多屏互动方法及***
CN103051694A (zh) * 2012-12-12 2013-04-17 北京奇虎科技有限公司 移动通信终端控制设备的方法与移动通信终端
CN103369035A (zh) * 2013-06-24 2013-10-23 四川长虹电器股份有限公司 基于二维码的智能家电通讯方法

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP2899956A4 *

Also Published As

Publication number Publication date
CN103647869A (zh) 2014-03-19
US20150289301A1 (en) 2015-10-08
CN103647869B (zh) 2016-04-27
EP2899956A1 (en) 2015-07-29
EP2899956A4 (en) 2016-07-27

Similar Documents

Publication Publication Date Title
WO2015070540A1 (zh) 一种终端的配对方法、终端及***
CN109495870B (zh) 蓝牙测试的方法和装置
US10243829B2 (en) Communication protocol testing method, and tested device and testing platform thereof
JP5068495B2 (ja) 分散型認証機能
CN111404695B (zh) 令牌请求验证方法和装置
WO2018018697A1 (zh) 伪基站垃圾短信鉴别方法及***
CN106714154B (zh) 用于通用自举架构协议的代理服务器、方法和***
CN113193974B (zh) 基于组播的行情信息推送方法、***、设备及介质
CN111541776A (zh) 一种基于物联网设备的安全通信装置及***
CN109561049B (zh) 一种基于监控业务的动态准入方法及装置
CN103997437A (zh) 一种测试云服务器注册功能的方法
CN102231667B (zh) 串口设备注册的方法和装置
WO2018141186A1 (zh) 一种volte网络性能测试方法及装置
CN107342994A (zh) 智能音响认证方法、智能音响、终端设备及***
CN111586017A (zh) 通信用户认证的方法和装置
CN106304071B (zh) 一种网络接入认证方法、接入认证设备及***
WO2012119537A1 (zh) 业务处理方法及***、机顶盒
CN105939317A (zh) Ssl握手报文的解析方法及装置
WO2011035577A1 (zh) 一种实现行业应用平台异地多媒体消息发送的方法及***
US7756083B2 (en) Network access device, network connection establishing method, and mobile communication system using the same
CA2593877A1 (en) Automatic mobile device configuration
WO2014201789A1 (zh) 一种业务处理方法、装置及***
US20240022614A1 (en) Information interaction method and apparatus
CN109788478B (zh) 一种在wpa无线网络中利用认证过程收集数据的方法
CN111949542B (zh) 回归测试或者压力测试的生成数据的提取方法及装置

Legal Events

Date Code Title Description
REEP Request for entry into the european phase

Ref document number: 2014814728

Country of ref document: EP

WWE Wipo information: entry into national phase

Ref document number: 2014814728

Country of ref document: EP

WWE Wipo information: entry into national phase

Ref document number: 14413325

Country of ref document: US

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 14814728

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE