WO2015120795A1 - Touchscreen-based device pairing method and apparatus, and storage medium - Google Patents

Touchscreen-based device pairing method and apparatus, and storage medium Download PDF

Info

Publication number
WO2015120795A1
WO2015120795A1 PCT/CN2015/072767 CN2015072767W WO2015120795A1 WO 2015120795 A1 WO2015120795 A1 WO 2015120795A1 CN 2015072767 W CN2015072767 W CN 2015072767W WO 2015120795 A1 WO2015120795 A1 WO 2015120795A1
Authority
WO
WIPO (PCT)
Prior art keywords
pairing
shared code
area
touch screen
paired
Prior art date
Application number
PCT/CN2015/072767
Other languages
French (fr)
Chinese (zh)
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 中兴通讯股份有限公司
Publication of WO2015120795A1 publication Critical patent/WO2015120795A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B5/00Near-field transmission systems, e.g. inductive loop type

Definitions

  • the present invention relates to a technology for terminal pairing in the field of wireless communication technologies, and in particular, to a touch screen-based device pairing method, device, and storage medium.
  • Bluetooth technology is a unified bridge for various peripheral interfaces in the network. It eliminates the connection between devices and replaces them with wireless connections. Bluetooth technology has more and more widely used applications, it has the advantages of openness, wireless, compatibility, low price, and little impact on the human body. But any technology has advantages and disadvantages, as does Bluetooth technology.
  • Bluetooth pairing between mobile intelligent terminals is cumbersome, especially when pairing between multiple devices often requires one setting, which is inconvenient when establishing device connection.
  • Devices with Bluetooth short-range radio capability need to search for Bluetooth-equipped devices before pairing, select the user name of the device to be paired from the device list, and require the user to enter an identification number or personal identification number (PIN). After the input identification number or PIN is verified, device pairing can be realized, thereby implementing device pairing connection.
  • embodiments of the present invention are directed to a touch screen-based device pairing method, apparatus, and storage medium.
  • An embodiment of the present invention provides a touch screen-based device pairing method, where the method includes: the device to be paired divides the touch screen into at least two regions; when receiving a pressing instruction of the contact, determining, according to the divided region Depressing a pressing area to which the contact belongs; generating a first shared code according to the pressing area; establishing a pairing relationship according to the first shared code.
  • An embodiment of the present invention provides a touch screen-based device pairing device, the device comprising: a partitioning unit, an area determining unit, a shared code generating unit, and a pairing unit; wherein the partitioning unit is configured to divide the touch screen into at least a region determining unit configured to determine a pressing region to which the contact belongs according to the divided region when receiving a pressing instruction of the contact; the sharing code generating unit configured to be configured according to the Pressing the area generates a first shared code; the pairing unit is configured to establish a pairing relationship according to the first shared code.
  • Embodiments of the present invention also provide a computer storage medium in which a computer program for executing the above-described touch screen based device pairing method is stored.
  • the device to be paired divides the touch screen into at least two regions; when receiving the pressing instruction of the contact, according to the divided region Determining a pressing area to which the contact belongs; generating a first sharing code according to the pressing area; establishing a pairing relationship according to the first shared code; thus, replacing the cumbersome device pairing process with a simple interface operation to make the device
  • the process of pairing becomes more rapid, convenient, and safe, and the method of the embodiment of the present invention is simple to implement and easy to popularize.
  • FIG. 1 is a schematic flowchart of an implementation process of a device for pairing a touch screen based device according to Embodiment 1 of the present invention
  • FIG. 2 is a schematic diagram of a method for dividing a touch screen area according to Embodiment 1 of the present invention
  • FIG. 3 is a schematic flowchart of a device for pairing a touch screen based device according to Embodiment 2 of the present invention.
  • FIG. 4 is a schematic structural diagram of a device for pairing a touch screen based device according to Embodiment 3 of the present invention.
  • the device to be paired divides the touch screen into at least two regions, and when receiving a pressing instruction of the contact, determining a pressing region to which the contact belongs according to the divided region; The area generates a first shared code; a pairing relationship is established according to the first shared code.
  • the establishing a pairing relationship according to the first shared code is: determining that the first shared code is consistent with the second shared code, establishing a pairing relationship; and the second shared code is a shared code generated by the target pairing device of the device to be paired .
  • a touch screen-based device pairing method includes the following steps:
  • Step 101 The device to be paired divides the touch screen into at least two areas;
  • the device to be paired sets the number of the touch screen partition according to the screen size and the screen resolution of the touch screen of the target paired device, and the number of the set is at least 2; according to the set number and the resolution of the touch screen itself, the divided each is determined.
  • the vertex coordinates of the regions, and the range of each region is determined according to the coordinates of all the vertices of each region;
  • the target pairing device is a plurality of devices having different touch screen screen sizes
  • the number and shape of the area to be paired with the paired devices are consistent, and different devices are in different devices.
  • the extent of each zone is determined by the screen resolution of its own touch screen.
  • the shape of each of the divided regions is not limited, and may be various shapes such as a square, a rectangle, and a polygon, and the region is determined for each region to be divided according to the vertex coordinates of each region.
  • the number of touch screen partitions of the device to be paired can also be set by the user according to actual conditions.
  • the touch screen can be divided into multiple regions with different numbers and different shapes.
  • Step 102 When receiving a pressing instruction of the contact, the device to be paired determines, according to the divided area, a pressing area to which the contact belongs;
  • the device to be paired receives the pressing instruction reported by the contact contacted by the user with the touch screen, according to the coordinates of all the vertices and the coordinates of the contact of each region divided in step 101.
  • Point determining the pressing area to which the contact belongs; wherein the pressing command reported by the contact carries the coordinate point of the contact; all the vertex coordinates of each divided area are in pixels (pixel), and accordingly, the contact coordinate point In pixels (pixel).
  • Step 103 The device to be paired generates a first shared code according to the pressed area.
  • the to-be-paired device extracts a first shared code corresponding to the pressed area according to the pressing area; wherein the first shared code is a pre-agreed PIN, or a device category code; here, the PIN And the device category code may be a string of numbers preset in accordance with different areas divided by the touch screen, or a string of case-insensitive letters, or a combination of letters and numbers.
  • the shared codes stored in the paired two or more paired devices are consistent, so that when the user presses the same area on different paired devices, the extracted according to the pressed area
  • the shared code is the same; for each partitioning method, each area divided in each partitioning mode has a one-to-one correspondence with the shared code, and the shared code can be saved in the memory in advance, and when the shared code needs to be generated, the pressing area can be directly extract.
  • Step 104 The paired device establishes a pairing relationship according to the first shared code.
  • the device to be paired receives the second shared code generated by the target pairing device, and the first Matching the shared code with the second shared code; when the first shared code is consistent with the second shared code, determining that the paired device is successfully paired with the target paired device, establishing a pairing relationship; when the first shared code is When the second shared code is inconsistent, it is determined that the paired device fails to pair with the target paired device.
  • the process of generating the second shared code by the target pairing device is consistent with the process of generating the first shared code by the device to be paired, and is the same as steps 101 to 103.
  • the method of the embodiment of the present invention can be used for pairing multiple pairs of devices.
  • a pairing relationship can be established between multiple paired devices to implement a plurality of paired devices.
  • File sharing and application sharing, data interaction between multiple paired devices for example, when multiple paired devices are respectively equipped with shared game applications, wireless online games between multiple paired devices; here, paired devices Pairing between them can be Bluetooth pairing.
  • the number of touch screen divisions in step 101 should not be excessive. If the number of touch screen divisions is too large, the area of each area divided may be too small, and the user may easily press to the adjacent area of the target pressing area when pairing, so the area of the smallest area divided here should not be smaller than the finger. The area of the finger pad.
  • the first shared code is a shared code generated by the current device to be paired
  • the second shared code is a shared code generated by the target paired device of the device to be paired; here, the target relationship between the device to be paired and the target paired device
  • the first shared code is also opposite to the second shared code.
  • the shared code generated by itself is the first shared code (that is, the second shared code in step 104)
  • the shared code generated by the paired device is the second shared code (ie, the first shared code in step 104).
  • FIG. 2 illustrates an example of dividing a touch screen into four rectangular regions of equal size, and illustrating a method for dividing a touch screen region in step 101, as shown in FIG. 2:
  • the screen resolution of the touch screen (the part of the thick line siege) is m pixels*n pixels, the lower left corner is the origin of the touch screen coordinate point, and X ij (a, b) represents the jth vertex of the i th area Vertex coordinates, a is the coordinate value of the horizontal direction of the touch screen, b is the coordinate value of the vertical direction of the touch screen; for the touch screen, the number of the screen size and the screen resolution in the horizontal direction is smaller than the vertical direction.
  • the vertex coordinates of the four regions can be used to quickly and easily determine the pressing area to which any contact on the touch screen belongs.
  • the manner of dividing the touch screen area described above refers to the area division of the paired device when pairing is performed for the first time; when the paired device is paired again, the area division of the target paired device and the area division mode of the device to be paired are detected. Inconsistent, the two paired devices need to be re-areaized. When the two paired devices have been paired before and the regions are consistently divided, the area division is not required. .
  • the screen resolution of the first embodiment of the present invention is further illustrated by taking the screen resolution of the touch screen as 1280 pixels*720 pixels and 854 pixels*480 pixels as an example.
  • the two touch screens are divided into regions as shown in FIG. ;
  • the range of the four areas of the touch screen with a screen resolution of 1280 pixels*720 pixels is:
  • the pressing area of the contact is the fourth area; when the contact coordinates of the touch screen of the user is (390, 400), the pressing area of the contact is the second region;
  • the contact coordinates of the user pressing the touch screen are (120, 305), and the pressing area of the contact is the fourth area.
  • the coordinates of the four vertices of the fourth region are X 41 (0, 427), X 42 (240, 427), X 43 (240, 854) and X 44 (0, 854), respectively.
  • FIG. 3 is a touch screen-based device pairing method according to Embodiment 2 of the present invention. As shown in FIG. 3, the device pairing method is used for Bluetooth pairing of two paired devices, and includes the following steps:
  • Step 301 The paired device scans the other paired devices by using Bluetooth to obtain a paired device list.
  • the two paired devices need to perform Bluetooth pairing
  • the first device of the first user and the second device of the second user simultaneously scan the other paired devices except themselves by using Bluetooth.
  • a paired device list wherein when the first device is a device to be paired, the second device is a target pairing device; and when the second device is a device to be paired, the first device is Pair the device with the target.
  • Step 302 The pairing device selects the target pairing device from the paired device list
  • the paired devices that are respectively scanned by the two paired devices may include other devices in addition to the target paired device, and at this time, the first device and the first device The second device selects the other party as the target pairing device.
  • Step 303 The pairing device touch screen displays a pairing operation interface
  • the touch screens of the two paired devices respectively display a pairing operation interface; wherein the pairing operation interface is used for the user to press for Bluetooth pairing.
  • Step 304 The pairing device determines the pressing area according to the contact point
  • the first device determines the pressing area of the first device according to the contact between the finger of the first user and the touch screen, and the area for pairing and dividing; similarly, the second The device determines a pressing area of the second device; here, the pressing area of the first device and the second device are the same.
  • Step 305 The pairing device generates a sharing code according to the pressing area.
  • the first device and the second device respectively generate a respective shared code according to the pressed area determined in step 304, where the shared code generated by the first device is the first shared code, and the shared code generated by the second device is the second
  • the shared code is the same; the first device and the second shared code generated by the two paired devices are the same in the step 304, wherein the shared code is the first device and the second device.
  • Step 306 The pairing device performs matching of the shared code.
  • the first device sends the first shared code to the second device by using the Bluetooth
  • the second device sends the second shared code to the first device by using the Bluetooth
  • the first device and the second device respectively Matching the first shared code with the second shared code to determine two shares
  • the use of the first device and the second device is used to distinguish the two paired devices, and is not used to restrict the device to be paired as the first device, and the target paired device as the second device.
  • the pairing of the two paired devices is implemented, but the method provided by the second embodiment of the present invention is
  • the number of paired devices is not limited, and the user can pair pairs of the paired devices by simultaneously pressing the same area of the touch screen of at least two paired devices, and sharing files and applications among the plurality of paired devices;
  • the areas defined by the touch screen are the same to achieve device pairing with each other.
  • the device pairing device includes: a partitioning unit 41, an area determining unit 42, a shared code generating unit 43, and pairing. Unit 44;
  • the partitioning unit 41 may be implemented by a central processing unit (CPU) of a device to be paired, and configured to divide the touch screen into at least two areas;
  • CPU central processing unit
  • the partitioning unit 41 is configured to set the number of the touch screen partitions, determine the vertex coordinates of each of the divided regions according to the set number and the resolution of the touch screen itself, and determine the range of each region according to the coordinates of all the vertices of each region;
  • the number of the touch screen partitions may be set according to the screen size and screen resolution of the touch screen of the device to be paired and the target paired device, or may be set by the user according to actual conditions.
  • the area judging unit 42 may be implemented by the CPU of the device to be paired and the signal processor, configured to determine a pressing area to which the contact belongs according to the divided area when receiving a pressing instruction of the contact;
  • the area judging unit 42 receives the pressing instruction reported by the contact contacted by the user with the touch screen, and determines the pressing area to which the contact belongs according to all the vertex coordinates of each area divided by the partitioning unit 41 and the coordinate point of the contact; Wherein, the pressing instruction reported by the contact carries the coordinate point of the contact; all the vertex coordinates of each of the divided regions are in pixels (pixel), and correspondingly, the contact coordinate point is in pixels (pixel).
  • the shared code generating unit 43 may be implemented by a CPU and a memory pair of the device to be paired, configured to generate a first shared code according to the pressed area;
  • the sharing code generating unit 43 extracts the first shared code corresponding to the pressed area according to the pressing area, and transmits the extracted first shared code to the pairing unit 44;
  • the shared code is a pre-agreed PIN, or device category code.
  • the pairing unit 44 may be implemented by a CPU and an interface chip of the device to be paired, and configured to establish a pairing relationship according to the first shared code;
  • the device to be paired with the device pairing device receives the second shared code of the target pairing device, and matches the first shared code with the second shared code; when the first shared code is consistent with the second shared code, determining The device to be paired with the device pairing device is successfully paired with the target pairing device, and the pairing relationship is established. When the first shared code is inconsistent with the second shared code, it is determined that the paired device and the target paired device where the device pairing device are located fail to be paired with the target paired device. .
  • the device pairing device provided in Embodiment 3 of the present invention is also provided in the target pairing device.
  • the device pairing device shown in FIG. 4 is opened before device pairing, and the device pairing device determines the range of each region according to the vertex coordinates of the divided regions reported by the touch screen driver.
  • the touch screen reports the coordinate point of the finger contact
  • the device pairing device provided in FIG. 4 determines the belonging of the contact coordinate point in the touch screen according to the screen resolution of the paired device and all vertex coordinates reported by the touch screen.
  • the paired device for pairing needs to pre-install the device pairing device shown in FIG. 4.
  • the touch screen-based device pairing method according to the first embodiment or the second embodiment of the present invention may also be stored in a computer readable storage medium if it is implemented in the form of a software function module and sold or used as a stand-alone product.
  • Embodiment 1, or Embodiment 2 of the present application can be provided as a method, system, or computer program product.
  • the present application can take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment in combination of software and hardware.
  • the application can take the form of a computer program product embodied on one or more computer-usable storage media containing computer usable program code, including but not limited to a USB flash drive, a mobile hard drive, a read only memory (ROM, Read-Only Memory), disk storage, CD-ROM, optical storage, etc.
  • a USB flash drive a mobile hard drive
  • a read only memory ROM, Read-Only Memory
  • disk storage CD-ROM, optical storage, etc.
  • the computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture comprising the instruction device.
  • the apparatus implements the functions specified in one or more blocks of a flow or a flow and/or block diagram of the flowchart.
  • These computer program instructions can also be loaded into a computer or other programmable data processing device Having a series of operational steps performed on a computer or other programmable device to produce computer-implemented processing such that instructions executed on a computer or other programmable device are provided for implementing one or more processes in a flowchart and/or Or block diagram the steps of a function specified in a box or multiple boxes.
  • the first embodiment or the second embodiment of the present invention further provides a computer storage medium, wherein the computer program is used to execute the touch screen-based device pairing method according to the first embodiment or the second embodiment of the present invention.
  • the embodiments of the present invention are implemented in a device pairing process by a simple interface operation, so that the process of device pairing becomes more rapid, convenient, and safe, and the method of the embodiment of the present invention is simple to implement and easy to promote.

Abstract

A touchscreen-based device pairing method and apparatus, and a storage medium. The method comprises: dividing, by a device to be paired, a touchscreen into at least two regions (101); when a pressing instruction of a contact is received, according to the divided regions, determining a pressing region to which the contact belongs (102); according to the pressing region, generating a first shared code (103); and according to the first shared code, establishing a pairing relationship (104).

Description

基于触摸屏的设备配对方法、装置及存储介质Touch screen-based device pairing method, device and storage medium 技术领域Technical field
本发明涉及无线通信技术领域终端配对的技术,尤其涉及一种基于触摸屏的设备配对方法、装置及存储介质。The present invention relates to a technology for terminal pairing in the field of wireless communication technologies, and in particular, to a touch screen-based device pairing method, device, and storage medium.
背景技术Background technique
随着信息时代的到来,人们获取信息的途径越来越多,随着电子信息产业的发展,移动智能终端逐渐成为人们获取信息的最主要的途径。目前移动智能终端都配有蓝牙模块,不同的移动智能终端通过蓝牙模块进行设备连接,以实现数据共享的目的。蓝牙技术是网络中各种外围设备接口的统一桥梁,它消除了设备之间的连线,取而代之以无线连接。蓝牙技术有着越来越广泛的应用,它具有开放性、无线性、兼容性、价格低廉、对人体影响小等优点。但是任何技术都有优缺点,蓝牙技术也是如此。With the advent of the information age, people have more and more ways to obtain information. With the development of the electronic information industry, mobile intelligent terminals have gradually become the most important way for people to obtain information. At present, mobile intelligent terminals are equipped with a Bluetooth module, and different mobile intelligent terminals connect devices through a Bluetooth module to achieve data sharing. Bluetooth technology is a unified bridge for various peripheral interfaces in the network. It eliminates the connection between devices and replaces them with wireless connections. Bluetooth technology has more and more widely used applications, it has the advantages of openness, wireless, compatibility, low price, and little impact on the human body. But any technology has advantages and disadvantages, as does Bluetooth technology.
现有技术中,移动智能终端间的蓝牙配对比较繁琐,尤其是多台设备之间的配对往往需要一个一个的设定,造成建立设备连接时不方便。具有蓝牙短距离无线电能力的设备在进行配对前需要搜索周围带有蓝牙功能的设备,从设备列表选择需要配对设备的用户名,并且需要用户输入识别号或个人识别码(PIN,Personal Identification Number),输入的识别号或PIN验证以后才能实现设备配对,从而实现设备配对连接。许多用户都将需要对列表进行分类整理并进一步输入PIN以对靠近的设备进行匹配视为繁琐的工作;同时,这会造成重大安全性弱点,因为许多用户未刻意去改变默认PIN,或者保留默认PIN,这就导致了用户设备的蓝牙功能开启时能够在不知晓的情况下被连接,导致用户的个人信息和重要数据泄露给其他用户,从而带来损失。 In the prior art, Bluetooth pairing between mobile intelligent terminals is cumbersome, especially when pairing between multiple devices often requires one setting, which is inconvenient when establishing device connection. Devices with Bluetooth short-range radio capability need to search for Bluetooth-equipped devices before pairing, select the user name of the device to be paired from the device list, and require the user to enter an identification number or personal identification number (PIN). After the input identification number or PIN is verified, device pairing can be realized, thereby implementing device pairing connection. Many users will need to sort the list and further enter the PIN to match nearby devices as a cumbersome task; at the same time, this creates significant security weaknesses because many users do not intentionally change the default PIN, or leave the default The PIN, which causes the Bluetooth function of the user device to be connected when it is not known, causes the user's personal information and important data to be leaked to other users, thereby causing losses.
发明内容Summary of the invention
为解决现有存在的技术问题,本发明实施例期望提供一种基于触摸屏的设备配对方法、装置及存储介质。In order to solve the existing technical problems, embodiments of the present invention are directed to a touch screen-based device pairing method, apparatus, and storage medium.
本发明实施例的技术方案是这样实现的:The technical solution of the embodiment of the present invention is implemented as follows:
本发明实施例提供了一种基于触摸屏的设备配对方法,所述方法包括:待配对设备将触摸屏划分为至少两个区域;当接收到触点的按压指令时,根据所述划分的区域确定所述触点所属的按压区域;根据所述按压区域生成第一共享代码;根据所述第一共享代码建立配对关系。An embodiment of the present invention provides a touch screen-based device pairing method, where the method includes: the device to be paired divides the touch screen into at least two regions; when receiving a pressing instruction of the contact, determining, according to the divided region Depressing a pressing area to which the contact belongs; generating a first shared code according to the pressing area; establishing a pairing relationship according to the first shared code.
本发明实施例提供了一种基于触摸屏的设备配对装置,所述装置包括:分区单元、区域判断单元、共享代码生成单元、以及配对单元;其中,所述分区单元,配置为将触摸屏划分为至少两个区域;所述区域判断单元,配置为当接收到触点的按压指令时,根据所述划分的区域确定所述触点所属的按压区域;所述共享代码生成单元,配置为根据所述按压区域生成第一共享代码;所述配对单元,配置为根据所述第一共享代码建立配对关系。An embodiment of the present invention provides a touch screen-based device pairing device, the device comprising: a partitioning unit, an area determining unit, a shared code generating unit, and a pairing unit; wherein the partitioning unit is configured to divide the touch screen into at least a region determining unit configured to determine a pressing region to which the contact belongs according to the divided region when receiving a pressing instruction of the contact; the sharing code generating unit configured to be configured according to the Pressing the area generates a first shared code; the pairing unit is configured to establish a pairing relationship according to the first shared code.
本发明实施例还提供了一种计算机存储介质,其中存储有计算机程序,该计算机程序用于执行上述的基于触摸屏的设备配对方法。Embodiments of the present invention also provide a computer storage medium in which a computer program for executing the above-described touch screen based device pairing method is stored.
由此可见,本发明实施例提供的基于触摸屏的设备配对方法、装置及存储介质,待配对设备将触摸屏划分为至少两个区域;当接收到触点的按压指令时,根据所述划分的区域确定所述触点所属的按压区域;根据所述按压区域生成第一共享代码;根据所述第一共享代码建立配对关系;如此,将繁琐的设备配对过程通过简单的界面操作来代替,使设备配对的过程变得更加迅速、便捷、安全,且本发明实施例的方法实现简单,易于推广。Thus, the touch screen-based device pairing method and device and the storage medium provided by the embodiment of the present invention, the device to be paired divides the touch screen into at least two regions; when receiving the pressing instruction of the contact, according to the divided region Determining a pressing area to which the contact belongs; generating a first sharing code according to the pressing area; establishing a pairing relationship according to the first shared code; thus, replacing the cumbersome device pairing process with a simple interface operation to make the device The process of pairing becomes more rapid, convenient, and safe, and the method of the embodiment of the present invention is simple to implement and easy to popularize.
附图说明DRAWINGS
图1为本发明实施例一提供的一种基于触摸屏的设备配对方法的实现流程示意图; 1 is a schematic flowchart of an implementation process of a device for pairing a touch screen based device according to Embodiment 1 of the present invention;
图2为本发明实施例一提供的一种触摸屏区域划分的方式示意图;2 is a schematic diagram of a method for dividing a touch screen area according to Embodiment 1 of the present invention;
图3为本发明实施例二提供的一种基于触摸屏的设备配对方法的流程示意图;3 is a schematic flowchart of a device for pairing a touch screen based device according to Embodiment 2 of the present invention;
图4为本发明实施例三提供的一种基于触摸屏的设备配对装置的结构示意图。FIG. 4 is a schematic structural diagram of a device for pairing a touch screen based device according to Embodiment 3 of the present invention.
具体实施方式detailed description
在本发明的实施例中,待配对设备将触摸屏划分为至少两个区域,当接收到触点的按压指令时,根据所述划分的区域确定所述触点所属的按压区域;根据所述按压区域生成第一共享代码;根据所述第一共享代码建立配对关系。In an embodiment of the present invention, the device to be paired divides the touch screen into at least two regions, and when receiving a pressing instruction of the contact, determining a pressing region to which the contact belongs according to the divided region; The area generates a first shared code; a pairing relationship is established according to the first shared code.
其中,根据所述第一共享代码建立配对关系为:确定所述第一共享代码与第二共享代码一致,建立配对关系;所述第二共享代码为待配对设备的目标配对设备生成的共享代码。The establishing a pairing relationship according to the first shared code is: determining that the first shared code is consistent with the second shared code, establishing a pairing relationship; and the second shared code is a shared code generated by the target pairing device of the device to be paired .
下面通过附图及具体实施例对本发明做进一步的详细说明。The invention will be further described in detail below with reference to the drawings and specific embodiments.
实施例一Embodiment 1
本发明实施例一提供的一种基于触摸屏的设备配对方法,如图1所示,包括以下步骤:A touch screen-based device pairing method according to Embodiment 1 of the present invention, as shown in FIG. 1, includes the following steps:
步骤101,待配对设备将触摸屏划分为至少两个区域;Step 101: The device to be paired divides the touch screen into at least two areas;
具体的,待配对设备根据自身与目标配对设备的触摸屏的屏幕尺寸、屏幕分辨率,设置触摸屏分区的数量,设置的数量至少为2;根据设置的数量与触摸屏自身的分辨率确定划分后的每个区域的顶点坐标,根据每个区域的所有顶点坐标确定每个区域的范围;Specifically, the device to be paired sets the number of the touch screen partition according to the screen size and the screen resolution of the touch screen of the target paired device, and the number of the set is at least 2; according to the set number and the resolution of the touch screen itself, the divided each is determined. The vertex coordinates of the regions, and the range of each region is determined according to the coordinates of all the vertices of each region;
其中,当目标配对设备为触摸屏屏幕尺寸不同的多个设备时,待配对设备与这些目标配对所划分的区域的数量、形状保持一致,不同的设备中 每个区域的范围根据自身触摸屏的屏幕分辨率大小确定。这里,对划分后的每个区域的形状不做限制,可为正方形、矩形、多边形等各种形状,针对所划分的每个区域,根据每个区域的顶点坐标来确定该区域。Wherein, when the target pairing device is a plurality of devices having different touch screen screen sizes, the number and shape of the area to be paired with the paired devices are consistent, and different devices are in different devices. The extent of each zone is determined by the screen resolution of its own touch screen. Here, the shape of each of the divided regions is not limited, and may be various shapes such as a square, a rectangle, and a polygon, and the region is determined for each region to be divided according to the vertex coordinates of each region.
在实际应用中,当用户需要进行配对时,待配对设备触摸屏分区的数量也可由用户根据实际情况进行设置。对于同一个待配对设备与不同的目标配对设备配对时,可将触摸屏划分为数量不同,形状不同的多个区域。In practical applications, when the user needs to perform pairing, the number of touch screen partitions of the device to be paired can also be set by the user according to actual conditions. When the same paired device is paired with different target paired devices, the touch screen can be divided into multiple regions with different numbers and different shapes.
步骤102,当接收到触点的按压指令时,待配对设备根据所述划分的区域确定所述触点所属的按压区域;Step 102: When receiving a pressing instruction of the contact, the device to be paired determines, according to the divided area, a pressing area to which the contact belongs;
具体的,当用户按压待配对设备的触摸屏进行配对时,待配对设备接收到用户与触摸屏接触的触点上报的按压指令,根据步骤101中划分的每个区域的所有顶点坐标和触点的坐标点,确定触点所属的按压区域;其中,触点上报的按压指令携带有触点的坐标点;划分的每个区域的所有顶点坐标以像素(pixel)为单位,相应地,触点坐标点以像素(pixel)为单位。Specifically, when the user presses the touch screen of the device to be paired to perform pairing, the device to be paired receives the pressing instruction reported by the contact contacted by the user with the touch screen, according to the coordinates of all the vertices and the coordinates of the contact of each region divided in step 101. Point, determining the pressing area to which the contact belongs; wherein the pressing command reported by the contact carries the coordinate point of the contact; all the vertex coordinates of each divided area are in pixels (pixel), and accordingly, the contact coordinate point In pixels (pixel).
步骤103,待配对设备根据所述按压区域生成第一共享代码;Step 103: The device to be paired generates a first shared code according to the pressed area.
具体的,当确定触点的按压区域后,待配对设备根据按压区域提取与按压区域相对应的第一共享代码;其中,第一共享代码为预先约定的PIN、或设备类别码;这里,PIN和设备类别码可为根据触摸屏划分的不同区域预先设置的一串数字、或一串不区分大小写的字母、或字母和数字的组合。Specifically, after determining the pressing area of the contact, the to-be-paired device extracts a first shared code corresponding to the pressed area according to the pressing area; wherein the first shared code is a pre-agreed PIN, or a device category code; here, the PIN And the device category code may be a string of numbers preset in accordance with different areas divided by the touch screen, or a string of case-insensitive letters, or a combination of letters and numbers.
在实际应用中,针对位置相同的区域,进行配对的两个或两个以上的配对设备中保存的共享代码一致,这样,当用户按压不同配对设备上同一个区域时,根据按压区域所提取的共享代码相同;针对不同的分区方式,每种划分方式中划分的每个区域与共享代码是一一对应关系,共享代码可提前保存于内存中,当需要生成共享代码时,可根据按压区域直接提取。In an actual application, for the same location area, the shared codes stored in the paired two or more paired devices are consistent, so that when the user presses the same area on different paired devices, the extracted according to the pressed area The shared code is the same; for each partitioning method, each area divided in each partitioning mode has a one-to-one correspondence with the shared code, and the shared code can be saved in the memory in advance, and when the shared code needs to be generated, the pressing area can be directly extract.
步骤104,待配对设备根据所述第一共享代码建立配对关系;Step 104: The paired device establishes a pairing relationship according to the first shared code.
具体的,待配对设备接收目标配对设备生成的第二共享代码,将第一 共享代码与所述第二共享代码进行匹配;当第一共享代码与所述第二共享代码一致时,确定待配对设备与目标配对设备配对成功,建立配对关系;当第一共享代码与所述第二共享代码不一致时,确定待配对设备与目标配对设备配对失败。Specifically, the device to be paired receives the second shared code generated by the target pairing device, and the first Matching the shared code with the second shared code; when the first shared code is consistent with the second shared code, determining that the paired device is successfully paired with the target paired device, establishing a pairing relationship; when the first shared code is When the second shared code is inconsistent, it is determined that the paired device fails to pair with the target paired device.
这里,目标配对设备生成第二共享代码的过程与待配对设备生成第一共享代码的过程一致,同步骤101至步骤103。Here, the process of generating the second shared code by the target pairing device is consistent with the process of generating the first shared code by the device to be paired, and is the same as steps 101 to 103.
在实际使用中,本发明实施例的方法可用于多个配对设备的配对,当多个配对设备同时按压同一区域时,可在多个配对设备之间建立配对关系,实现多个配对设备之间的文件共享和应用共享,在多个配对设备之间进行数据交互,例如,当多个配对设备分别装有共享的游戏应用时,在多个配对设备之间进行无线联机游戏;这里,配对设备之间进行的配对可为蓝牙配对。In actual use, the method of the embodiment of the present invention can be used for pairing multiple pairs of devices. When multiple paired devices simultaneously press the same area, a pairing relationship can be established between multiple paired devices to implement a plurality of paired devices. File sharing and application sharing, data interaction between multiple paired devices, for example, when multiple paired devices are respectively equipped with shared game applications, wireless online games between multiple paired devices; here, paired devices Pairing between them can be Bluetooth pairing.
在实际应用中,步骤101中的触摸屏划分的数量不宜过多。如果触摸屏划分的数量过多,则会导致划分的每个区域的面积过小,用户配对时容易按压到目标按压区域的相邻区域,所以,此处划分的最小区域的面积不应小于手指的指腹面积。In practical applications, the number of touch screen divisions in step 101 should not be excessive. If the number of touch screen divisions is too large, the area of each area divided may be too small, and the user may easily press to the adjacent area of the target pressing area when pairing, so the area of the smallest area divided here should not be smaller than the finger. The area of the finger pad.
在实际应用中,第一共享代码为当前待配对设备自身生成的共享代码,而第二共享代码为待配对设备的目标配对设备生成的共享代码;这里,待配对设备与目标配对设备的目标关系是对应的,因此,第一共享代码与第二共享代码也是相对的,对于目标配对设备而言,自身生成的共享代码为第一共享代码(也就是步骤104中的第二共享代码),待配对设备生成的共享代码为第二共享代码(也就是步骤104中的第一共享代码)。In an actual application, the first shared code is a shared code generated by the current device to be paired, and the second shared code is a shared code generated by the target paired device of the device to be paired; here, the target relationship between the device to be paired and the target paired device Corresponding, therefore, the first shared code is also opposite to the second shared code. For the target paired device, the shared code generated by itself is the first shared code (that is, the second shared code in step 104), The shared code generated by the paired device is the second shared code (ie, the first shared code in step 104).
图2以将触摸屏划分为4个大小相等的矩形区域的区域划分方式为例,说明步骤101中触摸屏区域划分的方法,如图2所示:FIG. 2 illustrates an example of dividing a touch screen into four rectangular regions of equal size, and illustrating a method for dividing a touch screen region in step 101, as shown in FIG. 2:
将触摸屏划分为4个大小相等的矩形区域,划分后4个区域的范围分 别为:Divide the touch screen into four equal-sized rectangular areas, and divide the range of the last four areas. Don't be:
第一区域四个顶点坐标:Four vertex coordinates of the first region:
X11(0,0)、X12(m/2,0)、X13(m/2,n/2)、X14(0,n/2);X 11 (0,0), X 12 (m/2,0), X 13 (m/2,n/2), X 14 (0,n/2);
第二区域四个顶点坐标:Four vertex coordinates of the second region:
X21(m/2,0)、X22(m,0)、X23(m,n/2)、X24(m/2,n/2);X 21 (m/2,0), X 22 (m,0), X 23 (m,n/2), X 24 (m/2,n/2);
第三区域四个顶点坐标:Four corner coordinates of the third area:
X31(m/2,n/2)、X32(m,n/2)、X33(m,n)、X34(m/2,n);X 31 (m/2, n/2), X 32 (m, n/2), X 33 (m, n), X 34 (m/2, n);
第四区域四个顶点坐标:Four vertex coordinates of the fourth region:
X41(0,n/2)、X42(m/2,n/2)、X43(m/2,n)、X44(0,n)。X 41 (0, n/2), X 42 (m/2, n/2), X 43 (m/2, n), X 44 (0, n).
其中,触摸屏(粗线围城的部分)的屏幕分辨率为m pixels*n pixels,以左下角点为触摸屏坐标点的原点,Xij(a,b)表示第i个区域的第j个顶点的顶点坐标,a为触摸屏的水平方向的坐标值,b为触摸屏的垂直方向的坐标值;对于触摸屏,水平方向的屏幕尺寸与屏幕分辨率的数字相对于垂直方向较小。Wherein, the screen resolution of the touch screen (the part of the thick line siege) is m pixels*n pixels, the lower left corner is the origin of the touch screen coordinate point, and X ij (a, b) represents the jth vertex of the i th area Vertex coordinates, a is the coordinate value of the horizontal direction of the touch screen, b is the coordinate value of the vertical direction of the touch screen; for the touch screen, the number of the screen size and the screen resolution in the horizontal direction is smaller than the vertical direction.
通过这4个区域的顶点坐标可方便快捷的确定触摸屏上任意一触点所属的按压区域。The vertex coordinates of the four regions can be used to quickly and easily determine the pressing area to which any contact on the touch screen belongs.
其中,上面描述的触摸屏区域划分的方式,是指待配对设备在初次进行配对时的区域划分;当待配对设备再次进行配对时,检测到目标配对设备的区域划分与待配对设备的区域划分方式不一致,需要对两个配对设备重新进行区域划分;当两个配对设备之前已进行过配对,且其区域的划分一致的情况下,可不需要重新进行区域划分,而是采用之前保存的区域划分方式。The manner of dividing the touch screen area described above refers to the area division of the paired device when pairing is performed for the first time; when the paired device is paired again, the area division of the target paired device and the area division mode of the device to be paired are detected. Inconsistent, the two paired devices need to be re-areaized. When the two paired devices have been paired before and the regions are consistently divided, the area division is not required. .
分别以触摸屏的屏幕分辨率为1280pixels*720pixels、854pixels*480pixels为例,对本发明实施例一中的图2进行进一步说明;两个触摸屏在进行区域划分时均采用如图2所示的区域划分方式; The screen resolution of the first embodiment of the present invention is further illustrated by taking the screen resolution of the touch screen as 1280 pixels*720 pixels and 854 pixels*480 pixels as an example. The two touch screens are divided into regions as shown in FIG. ;
屏幕分辨率为1280pixels*720pixels的触摸屏的4个区域的范围分别为:The range of the four areas of the touch screen with a screen resolution of 1280 pixels*720 pixels is:
第一区域四个顶点坐标:Four vertex coordinates of the first region:
X11(0,0)、X12(360,0)、X13(360,640)、X14(0,640);X 11 (0,0), X 12 (360,0), X 13 (360,640), X 14 (0,640);
第二区域四个顶点坐标:Four vertex coordinates of the second region:
X21(360,0)、X22(720,0)、X23(720,640)、X24(360,640);X 21 (360,0), X 22 (720,0), X 23 (720,640), X 24 (360,640);
第三区域四个顶点坐标:Four corner coordinates of the third area:
X31(360,640)、X32(720,640)、X33(720,1280)、X34(360,1280);X 31 (360, 640), X 32 (720, 640), X 33 (720, 1280), X 34 (360, 1280);
第四区域四个顶点坐标:Four vertex coordinates of the fourth region:
X41(0,640)、X42(360,640)、X43(360,1280)、X44(0,1280)。X 41 (0,640), X 42 (360, 640), X 43 (360, 1280), X 44 (0, 1280).
当用户按压触摸屏的触点坐标为(200,725)时,触点的按压区域为第四区域;当用户按压触摸屏的触点坐标为(390,400)时,触点的按压区域为第二区域;When the contact coordinates of the touch screen of the user are (200, 725), the pressing area of the contact is the fourth area; when the contact coordinates of the touch screen of the user is (390, 400), the pressing area of the contact is the second region;
同理,当屏幕分辨率为854pixels*480pixels的触摸屏采用如图2所示的区域划分的方式时,用户按压触摸屏的触点坐标为(120,305),则触点的按压区域为第四区域;其中,第四区域的四个顶点的坐标分别为X41(0,427),X42(240,427),X43(240,854)和X44(0,854)。Similarly, when the touch screen with a screen resolution of 854 pixels*480 pixels uses the area division as shown in FIG. 2, the contact coordinates of the user pressing the touch screen are (120, 305), and the pressing area of the contact is the fourth area. Wherein the coordinates of the four vertices of the fourth region are X 41 (0, 427), X 42 (240, 427), X 43 (240, 854) and X 44 (0, 854), respectively.
实施例二Embodiment 2
图3为本发明实施例二提供的一种基于触摸屏的设备配对方法,如图3所示,该设备配对方法用于两个配对设备的蓝牙配对,包括以下步骤:FIG. 3 is a touch screen-based device pairing method according to Embodiment 2 of the present invention. As shown in FIG. 3, the device pairing method is used for Bluetooth pairing of two paired devices, and includes the following steps:
步骤301:配对设备使用蓝牙扫描其他配对设备,得到配对设备列表;Step 301: The paired device scans the other paired devices by using Bluetooth to obtain a paired device list.
这里,当两个配对设备(第一设备、第二设备)需要进行蓝牙配对时,第一用户的第一设备与第二用户的第二设备同时使用蓝牙扫描除自身外的其他配对设备,得到配对设备列表,其中,当第一设备为待配对设备时,第二设备为目标配对设备;相对的,第二设备为待配对设备时,第一设备 为目标配对设备。Here, when the two paired devices (the first device, the second device) need to perform Bluetooth pairing, the first device of the first user and the second device of the second user simultaneously scan the other paired devices except themselves by using Bluetooth. a paired device list, wherein when the first device is a device to be paired, the second device is a target pairing device; and when the second device is a device to be paired, the first device is Pair the device with the target.
步骤302:配对设备从配对设备列表中选择目标配对设备;Step 302: The pairing device selects the target pairing device from the paired device list;
本步骤中,当第一设备与第二设备进行蓝牙扫描后,两个配对设备分别扫描到的配对设备列表中除了目标配对设备之外,可能还包括其他的设备,此时,第一设备与第二设备分别选择对方为目标配对设备。In this step, after the first device and the second device perform a Bluetooth scan, the paired devices that are respectively scanned by the two paired devices may include other devices in addition to the target paired device, and at this time, the first device and the first device The second device selects the other party as the target pairing device.
步骤303:配对设备触摸屏显示配对操作界面;Step 303: The pairing device touch screen displays a pairing operation interface;
具体的,当第一设备与第二设备分别选择目标配对设备后,两个配对设备的触摸屏分别显示配对操作界面;其中,配对操作界面用于用户按压,以进行蓝牙配对。Specifically, after the first device and the second device respectively select the target pairing device, the touch screens of the two paired devices respectively display a pairing operation interface; wherein the pairing operation interface is used for the user to press for Bluetooth pairing.
步骤304:配对设备根据触点确定按压区域;Step 304: The pairing device determines the pressing area according to the contact point;
本步骤中,当第一用户按压第一设备的触摸屏时,第一设备根据第一用户的手指与触摸屏的触点、用于配对划分的区域确定第一设备的按压区域;同理,第二设备确定第二设备的按压区域;这里,第一设备与第二设备的按压区域相同。In this step, when the first user presses the touch screen of the first device, the first device determines the pressing area of the first device according to the contact between the finger of the first user and the touch screen, and the area for pairing and dividing; similarly, the second The device determines a pressing area of the second device; here, the pressing area of the first device and the second device are the same.
步骤305:配对设备根据按压区域生成共享代码;Step 305: The pairing device generates a sharing code according to the pressing area.
具体的,第一设备和第二设备分别根据步骤304中确定的按压区域生成各自的共享代码,其中,第一设备生成的共享代码为第一共享代码,第二设备生成的共享代码为第二共享代码;步骤304中第一设备与第二设备的按压区域相同,对应地,两个配对设备生成的第一共享代码与第二共享代码也相同;其中,共享代码为第一设备与第二设备预先约定的PIN或蓝牙设备类别码。Specifically, the first device and the second device respectively generate a respective shared code according to the pressed area determined in step 304, where the shared code generated by the first device is the first shared code, and the shared code generated by the second device is the second The shared code is the same; the first device and the second shared code generated by the two paired devices are the same in the step 304, wherein the shared code is the first device and the second device. Pre-agreed PIN or Bluetooth device category code for the device.
步骤306:配对设备进行共享代码的匹配;Step 306: The pairing device performs matching of the shared code.
具体的,第一设备通过蓝牙将第一共享代码发送给第二设备,第二设备通过蓝牙将第二共享代码发送给第一设备,所述第一设备与所述第二设备分别将所述第一共享代码与所述第二共享代码进行匹配,确定两个共享 代码相同时,建立配对关系,配对成功;否则,配对失败。Specifically, the first device sends the first shared code to the second device by using the Bluetooth, and the second device sends the second shared code to the first device by using the Bluetooth, where the first device and the second device respectively Matching the first shared code with the second shared code to determine two shares When the code is the same, the pairing relationship is established and the pairing is successful; otherwise, the pairing fails.
图3所示的设备配对方法中,第一设备与第二设备的使用是用于将两个配对设备进行区别,并非用于限制待配对设备为第一设备,目标配对设备为第二设备。In the device pairing method shown in FIG. 3, the use of the first device and the second device is used to distinguish the two paired devices, and is not used to restrict the device to be paired as the first device, and the target paired device as the second device.
图3所示的设备配对方法中,以两个配对设备为例说明了当用户按压两个配对设备触摸屏的同一区域时,实现两个配对设备的配对,但本发明实施例二提供的方法并不对配对设备的个数进行限制,用户可通过同时按压至少两个配对设备触摸屏的同一区域,实现多个配对设备的配对,在多个配对设备之间共享文件和应用;其中,所有配对设备的触摸屏所划分的区域相同,以实现相互之间的设备配对。In the device pairing method shown in FIG. 3, taking two paired devices as an example, when the user presses the same area of the touch screen of two paired devices, the pairing of the two paired devices is implemented, but the method provided by the second embodiment of the present invention is The number of paired devices is not limited, and the user can pair pairs of the paired devices by simultaneously pressing the same area of the touch screen of at least two paired devices, and sharing files and applications among the plurality of paired devices; The areas defined by the touch screen are the same to achieve device pairing with each other.
实施例三Embodiment 3
图4为本发明实施例三提供的一种基于触摸屏的设备配对装置的结构示意图,如图4示,该设备配对装置包括:分区单元41、区域判断单元42、共享代码生成单元43、以及配对单元44;4 is a schematic structural diagram of a device for pairing a touch screen based device according to Embodiment 3 of the present invention. As shown in FIG. 4, the device pairing device includes: a partitioning unit 41, an area determining unit 42, a shared code generating unit 43, and pairing. Unit 44;
分区单元41可由待配对设备的中央处理器(CPU,Central Processing Unit)实现,配置为将触摸屏划分为至少两个区域;The partitioning unit 41 may be implemented by a central processing unit (CPU) of a device to be paired, and configured to divide the touch screen into at least two areas;
具体的,分区单元41配置为设置触摸屏分区的数量,根据设置的数量与触摸屏自身的分辨率确定划分后的每个区域的顶点坐标,根据每个区域的所有顶点坐标确定每个区域的范围;其中,所述数量至少为2;触摸屏分区数量的设置可根据装置所在待配对设备与目标配对设备的触摸屏的屏幕尺寸、屏幕分辨率进行设置,也可由用户根据实际情况进行设置。Specifically, the partitioning unit 41 is configured to set the number of the touch screen partitions, determine the vertex coordinates of each of the divided regions according to the set number and the resolution of the touch screen itself, and determine the range of each region according to the coordinates of all the vertices of each region; The number of the touch screen partitions may be set according to the screen size and screen resolution of the touch screen of the device to be paired and the target paired device, or may be set by the user according to actual conditions.
区域判断单元42可由待配对设备的CPU与信号处理器配合实现,配置为当接收到触点的按压指令时,根据所述划分的区域确定所述触点所属的按压区域;The area judging unit 42 may be implemented by the CPU of the device to be paired and the signal processor, configured to determine a pressing area to which the contact belongs according to the divided area when receiving a pressing instruction of the contact;
具体的,当用户按压该设备配对装置所在待配对设备的触摸屏进行配 对时,区域判断单元42接收到用户与触摸屏接触的触点上报的按压指令,则根据分区单元41划分的每个区域的所有顶点坐标和触点的坐标点,确定触点所属的按压区域;其中,触点上报的按压指令携带有触点的坐标点;划分的每个区域的所有顶点坐标以像素(pixel)为单位,相应地,触点坐标点以像素(pixel)为单位。Specifically, when the user presses the touch screen of the device to be paired with the device pairing device, In time, the area judging unit 42 receives the pressing instruction reported by the contact contacted by the user with the touch screen, and determines the pressing area to which the contact belongs according to all the vertex coordinates of each area divided by the partitioning unit 41 and the coordinate point of the contact; Wherein, the pressing instruction reported by the contact carries the coordinate point of the contact; all the vertex coordinates of each of the divided regions are in pixels (pixel), and correspondingly, the contact coordinate point is in pixels (pixel).
共享代码生成单元43可由待配对设备的CPU和存储器配对实现,配置为根据所述按压区域生成第一共享代码;The shared code generating unit 43 may be implemented by a CPU and a memory pair of the device to be paired, configured to generate a first shared code according to the pressed area;
具体的,当区域判断单元42确定触点的按压区域后,共享代码生成单元43根据按压区域提取与按压区域相对应的第一共享代码,将提取的第一共享代码发送至配对单元44;其中,共享代码为预先约定的PIN、或设备类别码。Specifically, after the area determining unit 42 determines the pressing area of the contact, the sharing code generating unit 43 extracts the first shared code corresponding to the pressed area according to the pressing area, and transmits the extracted first shared code to the pairing unit 44; The shared code is a pre-agreed PIN, or device category code.
配对单元44可由待配对设备的CPU和接口芯片配合实现,配置为根据所述第一共享代码建立配对关系;The pairing unit 44 may be implemented by a CPU and an interface chip of the device to be paired, and configured to establish a pairing relationship according to the first shared code;
具体的,所述设备配对所在的待配对设备接收目标配对设备的第二共享代码,将第一共享代码与第二共享代码进行匹配;当第一共享代码与第二共享代码一致时,确定所述设备配对装置所在的待配对设备与目标配对设备配对成功,建立配对关系;当第一共享代码与第二共享代码不一致时,确定所述设备配对装置所在的待配对设备与目标配对设备配对失败。Specifically, the device to be paired with the device pairing device receives the second shared code of the target pairing device, and matches the first shared code with the second shared code; when the first shared code is consistent with the second shared code, determining The device to be paired with the device pairing device is successfully paired with the target pairing device, and the pairing relationship is established. When the first shared code is inconsistent with the second shared code, it is determined that the paired device and the target paired device where the device pairing device are located fail to be paired with the target paired device. .
这里,目标配对设备中也设有本发明实施例三提供的设备配对装置。Here, the device pairing device provided in Embodiment 3 of the present invention is also provided in the target pairing device.
在实际应用中,在进行设备配对前先打开图4所示的设备配对装置,该设备配对装置根据触摸屏驱动上报的划分区域的顶点坐标确定每个区域的范围。当用户按压配对设备的触摸屏时,触摸屏把手指触点的坐标点上报,图4提供的设备配对装置根据配对设备的屏幕分辨率和触摸屏上报的所有顶点坐标判断触点坐标点在触摸屏中的所属区域;当用户按压不同配对设备触摸屏的同一区域,不同匹配对设备的触点坐标点都在相同的按压 区域,则生成相同的共享代码,此时配对设备配对成功;如果配对时用户没有按压不同配对设备触摸屏的同一区域,则配对失败。需要说明的是进行配对的配对设备需要预装图4所示的设备配对装置。In an actual application, the device pairing device shown in FIG. 4 is opened before device pairing, and the device pairing device determines the range of each region according to the vertex coordinates of the divided regions reported by the touch screen driver. When the user presses the touch screen of the paired device, the touch screen reports the coordinate point of the finger contact, and the device pairing device provided in FIG. 4 determines the belonging of the contact coordinate point in the touch screen according to the screen resolution of the paired device and all vertex coordinates reported by the touch screen. Area; when the user presses the same area of the touch screen of different paired devices, the contact points of different matching pairs of devices are all in the same pressing The area generates the same shared code, at which point the paired device is successfully paired; if the user does not press the same area of the touch screen of the different paired device when pairing, the pairing fails. It should be noted that the paired device for pairing needs to pre-install the device pairing device shown in FIG. 4.
本发明实施例一、或实施例二所述基于触摸屏的设备配对方法如果以软件功能模块的形式实现并作为独立的产品销售或使用时,也可以存储在一个计算机可读取存储介质中。基于这样的理解,本领域内的技术人员应明白,本申请的实施例一、或实施例二可提供为方法、系统、或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质上实施的计算机程序产品的形式,所述存储介质包括但不限于U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、磁盘存储器、CD-ROM、光学存储器等。The touch screen-based device pairing method according to the first embodiment or the second embodiment of the present invention may also be stored in a computer readable storage medium if it is implemented in the form of a software function module and sold or used as a stand-alone product. Based on such understanding, those skilled in the art will appreciate that Embodiment 1, or Embodiment 2 of the present application can be provided as a method, system, or computer program product. Thus, the present application can take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment in combination of software and hardware. Moreover, the application can take the form of a computer program product embodied on one or more computer-usable storage media containing computer usable program code, including but not limited to a USB flash drive, a mobile hard drive, a read only memory ( ROM, Read-Only Memory), disk storage, CD-ROM, optical storage, etc.
本申请是根据本申请实施例一至实施例三的任一实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present application is described in terms of a flowchart, and/or block diagram of a method, apparatus (system), and computer program product according to any one of embodiments 1 through 3 of the present application. It will be understood that each flow and/or block of the flowchart illustrations and/or FIG. These computer program instructions can be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing device to produce a machine for the execution of instructions for execution by a processor of a computer or other programmable data processing device. Means for implementing the functions specified in one or more of the flow or in a block or blocks of the flow chart.
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。The computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture comprising the instruction device. The apparatus implements the functions specified in one or more blocks of a flow or a flow and/or block diagram of the flowchart.
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备 上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded into a computer or other programmable data processing device Having a series of operational steps performed on a computer or other programmable device to produce computer-implemented processing such that instructions executed on a computer or other programmable device are provided for implementing one or more processes in a flowchart and/or Or block diagram the steps of a function specified in a box or multiple boxes.
相应的,本发明实施例一或实施例二还提供一种计算机存储介质,其中存储有计算机程序,该计算机程序用于执行本发明实施例一、或实施例二的基于触摸屏的设备配对方法。Correspondingly, the first embodiment or the second embodiment of the present invention further provides a computer storage medium, wherein the computer program is used to execute the touch screen-based device pairing method according to the first embodiment or the second embodiment of the present invention.
以上所述,仅为本发明的较佳实施例而已,并非用于限定本发明的保护范围,凡在本发明的精神和原则之内所作的任何修改、等同替换和改进等,均应包含在本发明的保护范围之内。The above is only the preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in Within the scope of protection of the present invention.
工业实用性Industrial applicability
综合本发明的各实施例,在设备配对过程中,通过简单的界面操作来实现,使设备配对的过程变得更加迅速、便捷、安全,且本发明实施例的方法实现简单,易于推广 The embodiments of the present invention are implemented in a device pairing process by a simple interface operation, so that the process of device pairing becomes more rapid, convenient, and safe, and the method of the embodiment of the present invention is simple to implement and easy to promote.

Claims (11)

  1. 一种基于触摸屏的设备配对方法,所述方法包括:A touch screen based device pairing method, the method comprising:
    待配对设备将触摸屏划分为至少两个区域;当接收到触点的按压指令时,根据所述划分的区域确定所述触点所属的按压区域;根据所述按压区域生成第一共享代码;根据所述第一共享代码建立配对关系。The device to be paired divides the touch screen into at least two regions; when receiving a pressing instruction of the contact, determining a pressing region to which the contact belongs according to the divided region; generating a first shared code according to the pressing region; The first shared code establishes a pairing relationship.
  2. 根据权利要求1所述的设备配对方法,其中,所述将所述触摸屏划分为至少两个区域,包括:The device pairing method according to claim 1, wherein the dividing the touch screen into at least two regions comprises:
    设置所述触摸屏分区的数量;Setting the number of the touch screen partitions;
    根据所述数量与所述触摸屏的分辨率确定所述划分后的每个区域的顶点坐标;Determining vertex coordinates of each of the divided regions according to the number and the resolution of the touch screen;
    根据所述顶点坐标确定每个区域的范围。A range of each region is determined based on the vertex coordinates.
  3. 根据权利要求2所述的设备配对方法,其中,所述根据所述划分的区域确定所述触点所属的按压区域为:根据所述划分的每个区域的所有顶点坐标和所述触点的坐标点,确定所述触点所属的按压区域。The device pairing method according to claim 2, wherein the determining the pressing area to which the contact belongs according to the divided area is: according to all vertex coordinates of the divided each area and the contact The coordinate point determines the pressing area to which the contact belongs.
  4. 根据权利要求1所述的设备配对方法,其中,所述根据所述按压区域生成第一共享代码,包括:根据所述按压区域提取与所述按压区域对应的第一共享代码;其中,所述第一共享代码为预先约定的个人识别码(PIN)、或设备类别码。The device pairing method according to claim 1, wherein the generating the first shared code according to the pressing area comprises: extracting a first sharing code corresponding to the pressing area according to the pressing area; wherein The first shared code is a pre-agreed personal identification number (PIN), or device category code.
  5. 根据权利要求1所述的设备配对方法,其中,所述根据所述第一共享代码建立配对关系为:确定所述第一共享代码与第二共享代码一致,建立配对关系;其中,所述第二共享代码为所述待配对设备的目标配对设备生成的共享代码。The device pairing method according to claim 1, wherein the establishing a pairing relationship according to the first shared code is: determining that the first shared code is consistent with the second shared code, establishing a pairing relationship; wherein the The shared code is a shared code generated by the target paired device of the device to be paired.
  6. 一种基于触摸屏的设备配对装置,所述装置包括:分区单元、区域判断单元、共享代码生成单元、以及配对单元;其中,A touch screen-based device pairing device, the device comprising: a partition unit, an area determining unit, a shared code generating unit, and a pairing unit; wherein
    所述分区单元,配置为将触摸屏划分为至少两个区域; The partitioning unit is configured to divide the touch screen into at least two areas;
    所述区域判断单元,配置为当接收到触点的按压指令时,根据所述划分的区域确定所述触点所属的按压区域;The area determining unit is configured to, when receiving a pressing instruction of the contact, determine a pressing area to which the contact belongs according to the divided area;
    所述共享代码生成单元,配置为根据所述按压区域生成第一共享代码;The shared code generating unit is configured to generate a first shared code according to the pressed area;
    所述配对单元,配置为根据所述第一共享代码建立配对关系。The pairing unit is configured to establish a pairing relationship according to the first shared code.
  7. 根据权利要求6所述的设备配对装置,其中,所述分区单元,配置为:The device pairing device according to claim 6, wherein the partitioning unit is configured to:
    设置所述触摸屏分区的数量;Setting the number of the touch screen partitions;
    根据所述数量与所述触摸屏的分辨率确定所述划分后的每个区域的顶点坐标;Determining vertex coordinates of each of the divided regions according to the number and the resolution of the touch screen;
    根据所述顶点坐标确定每个区域的范围。A range of each region is determined based on the vertex coordinates.
  8. 根据权利要求7所述的设备配对装置,其中,所述区域判断单元,配置为:根据所述划分的每个区域的所有顶点坐标和所述触点的坐标点,确定所述触点所属的按压区域。The device pairing device according to claim 7, wherein the area determining unit is configured to: determine, according to all vertex coordinates of each of the divided regions and coordinate points of the contacts, Press the area.
  9. 根据权利要求6所述的装置,其中,所述共享代码生成单元,配置为:根据所述按压区域提取与所述按压区域相对应的第一共享代码;The apparatus according to claim 6, wherein the shared code generating unit is configured to: extract a first shared code corresponding to the pressed area according to the pressed area;
    其中,所述第一共享代码为预先约定的PIN、或设备类别码。The first shared code is a pre-agreed PIN or a device category code.
  10. 根据权利要求6所述的装置,其中,所述配对单元,配置为确定所述第一共享代码与第二共享代码一致,建立配对关系;The device according to claim 6, wherein the pairing unit is configured to determine that the first shared code is consistent with the second shared code, establishing a pairing relationship;
    其中,所述第二共享代码为目标配对设备生成的共享代码,所述目标配对设备为所述装置所在的待配对设备的目标配对设备。The second shared code is a shared code generated by the target pairing device, and the target paired device is a target paired device of the device to be paired with the device.
  11. 一种计算机存储介质,其中存储有计算机程序,该计算机程序用于执行权利要求1至5任一项所述的基于触摸屏的设备配对方法。 A computer storage medium storing a computer program for performing the touch screen based device pairing method according to any one of claims 1 to 5.
PCT/CN2015/072767 2014-02-11 2015-02-11 Touchscreen-based device pairing method and apparatus, and storage medium WO2015120795A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201410048371.7 2014-02-11
CN201410048371.7A CN104834458A (en) 2014-02-11 2014-02-11 Equipment paring method and device based on touch screen

Publications (1)

Publication Number Publication Date
WO2015120795A1 true WO2015120795A1 (en) 2015-08-20

Family

ID=53799551

Family Applications (2)

Application Number Title Priority Date Filing Date
PCT/CN2014/079396 WO2015120676A1 (en) 2014-02-11 2014-06-06 Device pairing method and apparatus based on touch screen, and computer storage medium
PCT/CN2015/072767 WO2015120795A1 (en) 2014-02-11 2015-02-11 Touchscreen-based device pairing method and apparatus, and storage medium

Family Applications Before (1)

Application Number Title Priority Date Filing Date
PCT/CN2014/079396 WO2015120676A1 (en) 2014-02-11 2014-06-06 Device pairing method and apparatus based on touch screen, and computer storage medium

Country Status (2)

Country Link
CN (1) CN104834458A (en)
WO (2) WO2015120676A1 (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106101803B (en) * 2016-06-13 2020-06-02 Tcl移动通信科技(宁波)有限公司 Display screen control method and system of smart television
CN106210280A (en) * 2016-06-29 2016-12-07 宇龙计算机通信科技(深圳)有限公司 A kind of method of Bluetooth pairing, Apparatus and system
CN106304066B (en) * 2016-07-27 2019-11-26 维沃移动通信有限公司 A kind of authentication method and mobile terminal
CN108920068A (en) * 2018-05-29 2018-11-30 努比亚技术有限公司 A kind of edge interaction regulation method, equipment and computer readable storage medium
CN109542308A (en) * 2018-11-30 2019-03-29 努比亚技术有限公司 Picture-adjusting method, device, mobile terminal and readable storage medium storing program for executing
CN110488980B (en) * 2019-08-23 2024-03-22 大连成者科技有限公司 Human-computer interaction system of projection system

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102203794A (en) * 2011-06-01 2011-09-28 华为终端有限公司 A terminal authentication method and a device thereof
CN102478986A (en) * 2010-11-30 2012-05-30 汉王科技股份有限公司 Portable electronic equipment and information sharing method thereof
CN102629186A (en) * 2012-03-09 2012-08-08 南京商数信息技术有限公司 Method for establishing terminal matching through touch trajectory
CN102629182A (en) * 2012-02-28 2012-08-08 华为技术有限公司 Triggering method of communication application and electronic equipment
WO2013032222A1 (en) * 2011-08-29 2013-03-07 한국전자통신연구원 Method and system for communicating between devices
CN103209007A (en) * 2012-01-11 2013-07-17 中兴通讯股份有限公司 Bluetooth device quick pairing method and Bluetooth device
CN103246439A (en) * 2012-02-02 2013-08-14 三星电子株式会社 Short-range radio communication system and method for operating the same
TW201405323A (en) * 2012-06-29 2014-02-01 Nokia Corp Apparatus and method for selection of a device for content sharing operations

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1473899A1 (en) * 2003-04-28 2004-11-03 Telefonaktiebolaget LM Ericsson (publ) Security in a communications network
US8041035B2 (en) * 2005-12-30 2011-10-18 Intel Corporation Automatic configuration of devices upon introduction into a networked environment
CN101827360B (en) * 2010-04-09 2014-01-01 中兴通讯股份有限公司 Method and device for setting communication terminal graphical passwords
KR101425171B1 (en) * 2010-11-03 2014-08-04 한국전자통신연구원 Apparatus and method for input user password
CN102420641A (en) * 2011-12-01 2012-04-18 深圳市中兴移动通信有限公司 Method and system for realizing automatic matching connection of Bluetooth headset
CN103376997B (en) * 2012-04-18 2017-06-16 南京中兴新软件有限责任公司 A kind of method and device for touching screen unlocks
CN102723971B (en) * 2012-06-26 2014-09-24 宇龙计算机通信科技(深圳)有限公司 Bluetooth device and Bluetooth pairing method thereof
CN102857267A (en) * 2012-07-19 2013-01-02 中颖电子股份有限公司 Method and system for automatic pairing with Bluetooth human-computer interface device

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102478986A (en) * 2010-11-30 2012-05-30 汉王科技股份有限公司 Portable electronic equipment and information sharing method thereof
CN102203794A (en) * 2011-06-01 2011-09-28 华为终端有限公司 A terminal authentication method and a device thereof
WO2013032222A1 (en) * 2011-08-29 2013-03-07 한국전자통신연구원 Method and system for communicating between devices
CN103209007A (en) * 2012-01-11 2013-07-17 中兴通讯股份有限公司 Bluetooth device quick pairing method and Bluetooth device
CN103246439A (en) * 2012-02-02 2013-08-14 三星电子株式会社 Short-range radio communication system and method for operating the same
CN102629182A (en) * 2012-02-28 2012-08-08 华为技术有限公司 Triggering method of communication application and electronic equipment
CN102629186A (en) * 2012-03-09 2012-08-08 南京商数信息技术有限公司 Method for establishing terminal matching through touch trajectory
TW201405323A (en) * 2012-06-29 2014-02-01 Nokia Corp Apparatus and method for selection of a device for content sharing operations

Also Published As

Publication number Publication date
WO2015120676A1 (en) 2015-08-20
CN104834458A (en) 2015-08-12

Similar Documents

Publication Publication Date Title
WO2015120795A1 (en) Touchscreen-based device pairing method and apparatus, and storage medium
KR102167879B1 (en) Test methods, systems, devices and readable storage media
JP2019536554A (en) Object display method, terminal device, and computer storage medium
CN111352597B (en) Multi-screen display control method and device, electronic equipment and readable storage medium
CN107231607B (en) Unlocking method and device of Bluetooth intelligent lock and computer readable storage medium
CN105245346B (en) A kind of identity identifying method and user terminal
TWI695311B (en) Method, device and terminal for simulating mouse operation using gestures
KR20120047075A (en) Apparatus and method for input user password
JP6687222B2 (en) Terminal device password unlock method, device and terminal device
CN104978180B (en) Unprocessed event prompting method and device and mobile terminal
CN104320161A (en) Method and system for rapid Bluetooth pairing
WO2015184770A1 (en) Information processing method, system and terminal
CN104992120A (en) Picture encryption method and mobile terminal
US10747387B2 (en) Method, apparatus and user terminal for displaying and controlling input box
US20170124765A1 (en) Control method and information processing system
WO2017032127A1 (en) Pattern unlocking method and terminal
CN112000273A (en) Input method, device, equipment and computer readable storage medium
WO2016107229A1 (en) Icon displaying method and device, and computer storage medium
EP2746911A1 (en) Mobile electronic device and key display program
CN116137915A (en) Cross-device drawing system
US11489957B2 (en) Electronic device, external electronic device, and method for controlling external electronic device by using electronic device
CN110990821B (en) Identity type verification method, device and storage medium
KR101516565B1 (en) Apparatus and method for auhentication using an image
CN108363525B (en) Method and device for responding to user gesture operation in webpage and terminal equipment
CN107528965B (en) Lyric poster generation method and mobile terminal

Legal Events

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

Ref document number: 15749636

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 15749636

Country of ref document: EP

Kind code of ref document: A1