Connection establishment method and device, electronic equipment and medium
By obtaining user operating parameters and device location information, the target equipment is quickly determined, which solves the problem of cumbersome connection establishment process of wearable devices and improves connection efficiency.
Patent Information
- Application Number
- CN202410945519.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-15
- Publication Date
- 2024-11-22
AI Technical Summary
In the multi-device connection scenario, existing wearable devices need to perform cumbersome operation steps, resulting in slow connection establishment speed and reduced efficiency.
By obtaining the user's rotation or sliding parameters of the wearable device, combining the device position information and the position information of the connected device, the target device can be quickly determined from multiple connected devices, and the connection establishment between devices is achieved.
The connection establishment process is simplified and the connection efficiency between the wearable device and the connected device is improved. Users can complete the connection between devices with simple rotation or sliding operations.
Smart Images

Figure CN119012309A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of communication technology, and specifically relates to a connection establishment method, device, electronic device and medium. Background Art
[0002] Wearable devices have become standard in the daily lives of most users. In order to meet the growing demand for multi-device connections, users have begun to adopt a connection mode in which one wearable device connects to multiple connectable devices to obtain a more flexible usage experience.
[0003] In the related art, when there are multiple connectable devices within the wireless connection range of the wearable device, the wearable device can be paired with each connectable device, and establish a connection with a connectable device after the pairing is successful. Specifically, when the wearable device wants to establish a connection with a connectable device, the user's operation process includes: opening the connectable device, opening the wireless connection page of the connectable device, and clicking to confirm the connection on the wireless connection page of the connectable device.
[0004] It can be seen that in the above process of establishing a connection, the user needs to perform multiple operations on the connectable device, and the operation process is relatively cumbersome, resulting in a relatively slow speed of establishing the connection, which reduces the efficiency of establishing the connection between the wearable device and the connectable device. Summary of the invention
[0005] The purpose of the embodiments of the present application is to provide a connection establishment method, device, electronic device and medium, which can improve the efficiency of establishing a connection between a wearable device and a connectable device.
[0006] In a first aspect, an embodiment of the present application provides a connection establishment method, which is applied to a wearable device, and the method includes:
[0007] Acquire a first parameter, where the first parameter includes a rotation parameter or a sliding parameter of the wearable device by the user;
[0008] Determine a first device from the N connectable devices based on the first parameter, the first location information of the wearable device, and the N second location information corresponding to the N connectable devices, where N is an integer greater than 1;
[0009] A connection is established between the wearable device and the first device.
[0010] In a second aspect, an embodiment of the present application provides a connection establishment device, the device comprising:
[0011] An acquisition module, configured to acquire a first parameter, where the first parameter includes a rotation parameter or a sliding parameter of the wearable device by a user;
[0012] a determination module, configured to determine a first device from N connectable devices based on the first parameter acquired by the acquisition module, the first location information of the wearable device, and N second location information corresponding to the N connectable devices, where N is an integer greater than 1;
[0013] An establishing module is used to establish a connection between the wearable device and the first device determined by the determining module.
[0014] In a third aspect, an embodiment of the present application provides an electronic device, which includes a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the program or instructions are executed by the processor, the steps of the connection establishment method described in the first aspect are implemented.
[0015] In a fourth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the steps of the connection establishment method described in the first aspect are implemented.
[0016] In a fifth aspect, an embodiment of the present application provides a chip, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the connection establishment method as described in the first aspect.
[0017] In a sixth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the connection establishment method as described in the first aspect.
[0018] In the embodiment of the present application, the wearable device can determine the first device from the N connectable devices based on the first parameter, the first location information of the wearable device and the N second location information corresponding to the N connectable devices, and then establish a connection between the wearable device and the first device. In this solution, the wearable device can obtain the rotation parameter or sliding parameter of the wearable device by the user, that is, the wearable device can obtain the device that the user needs the wearable device to connect to according to the rotation or sliding operation performed by the user on the wearable device, that is, the user only needs to perform a simple rotation or sliding operation on the wearable device to trigger the wearable device to quickly determine the device that the user needs the wearable device to connect to, so that the wearable device locates the device that the user needs the wearable device to connect to from the multiple connectable devices according to its own location information and the location information of multiple connectable devices, and realizes the establishment of connection between the devices, thereby simplifying the operation process of the connection establishment process between the wearable device and the connectable device, and improving the efficiency of the connection establishment between the wearable device and the connectable device. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1 This is one of the flow charts of the connection establishment method provided in the embodiment of the present application;
[0020] Figure 2 is a schematic diagram of a user wearing a wearable device and rotating it according to an embodiment of the present application;
[0021] Figure 3 This is the second flow chart of the connection establishment method provided in the embodiment of the present application;
[0022] Figure 4 is a schematic diagram of an initial plane provided in an embodiment of the present application and a first plane parallel to the wearable device established after the user wears the wearable device and rotates;
[0023] Figure 5 This is the third flow chart of the connection establishment method provided in the embodiment of the present application;
[0024] Figure 6 This is a fourth flow chart of the connection establishment method provided in an embodiment of the present application;
[0025] Figure 7 is a schematic diagram of a connection establishment method provided in an embodiment of the present application;
[0026] Figure 8 This is the fifth flow chart of the connection establishment method provided in the embodiment of the present application;
[0027] Fig. 9 is a schematic diagram of a connection establishment method provided in an embodiment of the present application;
[0028] Fig.10 This is one of the structural schematic diagrams of the connection establishment device provided in the embodiment of the present application;
[0029] Fig.11 This is the second structural diagram of the connection establishment device provided in the embodiment of the present application;
[0030] Fig.12 is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application;
[0031] Fig.13 It is a schematic diagram of the hardware structure of the electronic device provided in the embodiment of the present application. DETAILED DESCRIPTION
[0032] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.
[0033] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.
[0034] The terms "at least one (item)", "at least one of" and the like in the specification and claims of the present application refer to any one, any two or a combination of more than two of the objects included therein. For example, at least one (item) of a, b, and c can be represented by: "a", "b", "c", "a and b", "a and c", "b and c" and "a, b and c", where a, b, and c can be single or multiple. Similarly, "at least two (items)" refers to two or more, and its meaning is similar to that of "at least one (item)".
[0035] The connection establishment method provided in the embodiment of the present application is described in detail below through specific embodiments and application scenarios in conjunction with the accompanying drawings.
[0036] The connection establishment method provided in the embodiment of the present application can be applied to a scenario in which a wearable device establishes a connection with a connectable device, or a scenario in which a wearable device switches from a connected connectable device to another connectable device.
[0037] For example, for a scenario where a wearable device switches connections with multiple connectable devices. When the wearable device is connected to an old device among the multiple connectable devices, if the user wants to switch the wearable device to a new device among the multiple connectable devices, the existing solution requires cumbersome operation steps: first open the old device, then open the wireless connection page of the old device, click Disconnect on the wireless connection page of the old device, then open the new device, open the wireless connection page of the new device, and click Confirm Connection on the wireless connection page of the new device. Furthermore, when both the old device and the new device are far away from the user, it is necessary to add the operation of walking near the old device and the new device, and the user has to perform more operation steps.
[0038] It can be seen that in the case of actively switching the connectable device connected to the wearable device, the existing solution requires the user to perform more steps and the operation process is cumbersome, resulting in a slow connection establishment speed, which reduces the efficiency of connection establishment between the wearable device and the connectable device.
[0039] To this end, an embodiment of the present application provides a connection establishment method, wherein the wearable device can determine the first device from N connectable devices based on a first parameter, the first location information of the wearable device, and the N second location information corresponding to the N connectable devices, wherein the first parameter includes a rotation parameter or a sliding parameter of the wearable device by the user, and then establishes a connection between the wearable device and the first device. In this solution, the wearable device can obtain the rotation parameter or the sliding parameter of the wearable device by the user, that is, the wearable device can obtain the device that the user requires the wearable device to connect to according to the rotation or sliding operation performed by the user on the wearable device, that is, the user only needs to perform a simple rotation or sliding operation on the wearable device to trigger the wearable device to quickly determine the device that the user requires the wearable device to connect to, so that the wearable device locates the device that the user requires the wearable device to connect to from multiple connectable devices according to its own location information and the location information of multiple connectable devices, and realizes the establishment of a connection between the devices, thereby simplifying the operation process of the connection establishment process between the wearable device and the connectable device, and improving the efficiency of the connection establishment between the wearable device and the connectable device.
[0040] The execution subject of the connection establishment method provided in the embodiment of the present application may be a connection establishment device. Exemplarily, the connection establishment device may be a wearable device, or a component in the wearable device, such as an integrated circuit or a chip. The following will take the execution subject as an example of a wearable device to exemplify the connection establishment method provided in the embodiment of the present application.
[0041] Figure 1 is a flow chart of a connection establishment method provided in an embodiment of the present application, such as Figure 1 As shown, the connection establishment method provided in the embodiment of the present application may include the following steps 101 to 103.
[0042] Step 101: The wearable device obtains a first parameter.
[0043] In the embodiment of the present application, the wearable device may include at least one of the following: a head-mounted device, a wrist-band device, the head-mounted device may include wireless headphones, smart glasses and other devices, the wrist-band device may include smart bracelets, smart watches and other devices, and the embodiment of the present application does not limit this. For example, the wearable device may be two wireless headphones.
[0044] In the embodiment of the present application, the above-mentioned first parameter may include a rotation parameter or a sliding parameter of the wearable device by the user.
[0045] In the embodiment of the present application, a gyroscope is configured in the wearable device. The user can wear the wearable device on the body, and when the user turns the body, the wearable device will also turn with the user, and the gyroscope of the wearable device can obtain the rotation parameters of the wearable device relative to the initial plane during this rotation.
[0046] In an embodiment of the present application, the above-mentioned initial plane may be a plane parallel to the wearable device when the wearable device is in an initial posture, and the initial posture may be set according to the type of the wearable device.
[0047] Exemplarily, when the wearable device is a head-mounted device, the rotation parameter of the wearable device by the user is the rotation parameter of the head-mounted device relative to the initial plane when the user wears the head-mounted device and turns his head. The initial posture may be the posture of the head-mounted device when the user wears the head-mounted device and remains still and looks straight ahead, and the initial plane may be a plane parallel to the user's face, and the initial plane is perpendicular to the ground plane.
[0048] As another example, when the wearable device is a wristband device, the rotation parameter of the wearable device by the user is the rotation parameter of the wristband device relative to the initial plane when the user wears the wristband device and rotates the wrist. The initial posture may be the posture of the wristband device when the user wears the wristband device and the arm hangs naturally, and the initial plane may be a plane parallel to the front of the wristband device, and the initial plane is perpendicular to the ground plane.
[0049] In the embodiment of the present application, the above-mentioned rotation parameter includes at least one of the following: rotation direction and rotation angle.
[0050] Example 1, taking the wearable device as a wireless headset as an example. Figure 2 As shown in (a) in FIG. 1 , the user wears a wireless headset and remains still and looks straight ahead. The initial plane 10 is parallel to the user's face and perpendicular to the ground plane. Figure 2 As shown in (b), when the user wears the wireless headset and turns his head, the wireless headset can obtain the rotation direction of the wireless headset relative to the initial plane 10 as direction d and the rotation angle as angle α through the gyroscope. Figure 2 , the user has turned the wireless headset in the left ear so that it cannot be seen.
[0051] In an embodiment of the present application, during the rotation of the wearable device, the gyroscope of the wearable device obtains its own angular velocity around each axis in real time as it rotates, integrates the angular velocity around each axis over time, and obtains the rotation angle of the gyroscope on each axis and the rotation direction of the gyroscope, and uses the rotation angle and rotation direction as the above-mentioned rotation parameters.
[0052] In the embodiment of the present application, a touch sensor is configured in the wearable device and a touch area is set. The user can wear the wearable device on the body, and when the user slides in the touch area of the wearable device, the touch sensor of the wearable device can obtain the sliding parameters of the wearable device during this sliding.
[0053] In the embodiment of the present application, the above sliding parameters may include at least one of the following: sliding direction, sliding distance.
[0054] Optionally, in the embodiment of the present application, the sliding direction may be the input direction of the user in the touch area detected by the wearable device, that is, the direction of the user sliding input in the touch area is taken as the sliding direction. Alternatively, the sliding direction may be a direction in a preset direction set corresponding to the input direction of the user in the touch area detected by the wearable device, that is, the direction in the preset direction set corresponding to the direction of the user sliding input in the touch area is taken as the sliding direction, and the preset direction set includes at least one direction correspondence, and each direction correspondence is a correspondence between a sliding input direction and a sliding direction.
[0055] Example 2, taking the wearable device as a wireless headset as an example. For the user, assuming that the user slides forward in the touch area of the wireless headset, the sliding direction obtained by the wearable device is the forward sliding input of the user in the touch area detected by the wireless headset, that is, the direction in front of the user's forward sliding input in the touch area is used as the sliding direction obtained by the wearable device. Alternatively, for the user, assuming that the user slides forward in the touch area of the wireless headset, the sliding direction obtained by the wearable device can be the direction in the preset direction set corresponding to the direction in which the user slides forward in the touch area as the sliding direction obtained by the wearable device, that is, the direction in the preset direction set corresponding to the direction in which the user slides forward in the touch area is used as the sliding direction obtained by the wearable device.
[0056] Optionally, in the embodiment of the present application, when the wearable device is already connected to a device, the user can trigger the wearable device to disconnect from the already connected device through input, and then establish a connection with another connectable device. Figure 1 ,like Figure 3 As shown, before the above step 101, the connection establishment method provided in the embodiment of the present application also includes the following steps 201 and 202.
[0057] Step 201: When the wearable device is connected to a second device, the wearable device receives a first input from a user.
[0058] In the embodiment of the present application, the second device is any type of electronic device that is currently connected to the wearable device. For example, the second device may be a mobile phone, a tablet computer, a laptop computer, a PDA, an in-vehicle electronic device, a mobile Internet device (MID), an augmented reality (AR) / virtual reality (VR) device, a robot, an ultra-mobile personal computer (UMPC), a netbook, a smart watch or a personal digital assistant (PDA), etc., and the embodiment of the present application does not specifically limit it.
[0059] It should be noted that, in the embodiment of the present application, the wearable device and the second device are connected, which may include: the wearable device and the second device have established a Bluetooth connection, the wearable device and the second device have established a wireless fidelity (wireless fidelity, Wi-Fi) connection, the wearable device and the second device have established a ZigBee connection, or the wearable device and the second device have established a near field communication (near field communication, NFC) connection and other wireless communication connections.
[0060] Exemplarily, the wearable device and the second device have established a Wi-Fi connection, which may include the wearable device being connected to the Wi-Fi network of the second device, such as the wearable device being connected to the hotspot network of the second device.
[0061] In the embodiment of the present application, the first input is an input of a user to a touch area in the wearable device, or an input of a user to a rotation of the wearable device.
[0062] Optionally, in the embodiment of the present application, when the first input is the user's input to the touch area of the wearable device, the first input may include but is not limited to: the user touches the touch area of the wearable device through a touch device such as a finger or a stylus, or a specific gesture input by the user in the touch area of the wearable device, or other feasible input by the user in the touch area of the wearable device. The specific input can be determined according to actual use requirements and is not limited in the embodiment of the present application.
[0063] Optionally, in an embodiment of the present application, the touch input may be a single-click input, a double-click input, or any number of click inputs, or may be a long-press input, a short-press input, or a sliding input, etc.
[0064] Optionally, in an embodiment of the present application, the above-mentioned specific gesture can be any one of a single-click gesture, a sliding gesture, a drag gesture, a pressure recognition gesture, a long press gesture, an area change gesture, a double-press gesture, and a double-click gesture.
[0065] Optionally, in an embodiment of the present application, a connection switching button is provided in the touch area in the wearable device, and the first input may be a user's touch input to the connection switching button in the touch area in the wearable device to trigger the wearable device to disconnect from the second device.
[0066] For example, taking the above-mentioned wearable device including two wireless earphones as an example, a connection switch button can be set in the touch area of one wireless earphone or in the touch areas of both wireless earphones. In the case where the connection switch button is set in both wireless earphones, the first input can be a user's click input on the connection switch button in the touch area of any wireless earphone.
[0067] Optionally, in an embodiment of the present application, the connection switching button may be a new button different from an existing button of the wearable device, or may be an existing button with a connection switching function after upgrading.
[0068] Exemplarily, in the case where the connection switching button is a new button, the first input may be a touch input of the user to the new button in the touch area of the wearable device.
[0069] For example, in the case where the connection switching button is an existing button that has a connection switching function after an upgrade, the wearable device can pre-set different touch inputs for the existing button to represent different functions, and the above-mentioned first input is the user's touch input representing the connection switching function of the existing button in the touch area of the wearable device.
[0070] For example, a single click input of an existing button by a user indicates a play function, a double click input indicates a song switching function, a long press input indicates a pause function, and a triple click input indicates a connection switching function. Therefore, the first input may be a triple click input of an existing button in a touch area of the wearable device by a user.
[0071] Optionally, in an embodiment of the present application, when the above-mentioned first input is a rotation input of the wearable device by the user, the above-mentioned first input may include but is not limited to: a rotation input of the wearable device when the user wears the wearable device and rotates it at a rotation angle greater than a first threshold, or a rotation input of the wearable device when the user wears the wearable device and rotates it at a rotation speed less than a second threshold.
[0072] It should be noted that the first threshold and the second threshold can be set or adjusted according to actual needs, and the embodiment of the present application does not limit this. For example, the first threshold can be 30 degrees, and the second threshold can be 90 degrees / second.
[0073] Step 202: The wearable device disconnects the wearable device from the second device in response to the first input.
[0074] In an embodiment of the present application, after receiving the first input, the wearable device disconnects the Bluetooth connection, Wi-Fi connection, ZigBee connection or NFC connection with the second device.
[0075] In this way, when the wearable device has established a connection with the second device, if the user wants to switch the wearable device to connect to other devices, the user only needs to perform a simple touch input on the wearable device to trigger the wearable device to disconnect from the second device so that it can subsequently establish a connection with other devices.
[0076] Step 102: The wearable device determines a first device from N connectable devices based on the first parameter, the first location information of the wearable device, and N second location information corresponding to the N connectable devices respectively.
[0077] In the embodiment of the present application, each second location information in the above-mentioned N second location information corresponds to a connectable device, and N is an integer greater than 1.
[0078] In the embodiment of the present application, the above-mentioned N connectable devices are devices that are within the wireless connection range of the wearable device and are successfully paired with the wearable device.
[0079] It should be noted that the connectable device described in the embodiment of the present application is any type of electronic device. For an explanation of the connectable device, please refer to the description of the second device mentioned above, which will not be repeated here.
[0080] In an embodiment of the present application, for M devices within the wireless connection range of the wearable device, when the wireless connection modes of the wearable device and N devices among the M devices are turned on, the wearable device is paired with the N devices respectively. The N devices after successful pairing are called N connectable devices, and M is an integer greater than or equal to N.
[0081] In the embodiment of the present application, after obtaining the first parameter, the wearable device can locate its own position information, i.e., the first position information, through a combination of a global positioning system (GPS), a Beidou positioning system, artificial intelligence and a variety of sensors. Alternatively, the wearable device can obtain its own position information, i.e., the first position information, from a stored set of its own position information.
[0082] In the embodiment of the present application, after obtaining the first parameter, the wearable device can obtain N second location information from the location information set of other devices stored in the wearable device. The N second location information is sent to the wearable device by the N connectable devices after the wearable device is successfully paired with the N connectable devices.
[0083] Optionally, in an embodiment of the present application, the first location information may include latitude and longitude information of the wearable device, coordinate information of the wearable device, or natural geographic location information of the wearable device.
[0084] Optionally, in an embodiment of the present application, the above-mentioned N second location information may include latitude and longitude information of N connectable devices, coordinate information of N connectable devices, natural geographical location information of N connectable devices, or relative location information of N connectable devices.
[0085] It should be noted that the relative position information of the N connectable devices may be the position information of the N connectable devices relative to the wearable device.
[0086] In the embodiment of the present application, after the wearable device is successfully paired with N connectable devices, each connectable device can send pairing information to the wearable device, and the pairing information can include the second location information of each connectable device. Therefore, after obtaining the first parameter, the above-mentioned wearable device can obtain N second location information from the location information set of other devices stored in itself.
[0087] Optionally, in the embodiment of the present application, the first parameter includes a rotation parameter, and the rotation parameter includes a rotation direction and a rotation angle of the wearable device relative to the initial plane. Exemplarily, the step 102 can be implemented by the following steps 301 and 302.
[0088] Step 301: The wearable device establishes a first plane based on the rotation direction, the rotation angle, and the first position information, and establishes N first straight lines based on the first position information and N second position information.
[0089] In the embodiment of the present application, each of the N first straight lines corresponds to a second position information.
[0090] In an embodiment of the present application, when the initial plane is known, the position of the wearable device can be used as a vertex, and based on a vertex, a rotation direction and a rotation angle, an edge can be determined, and then a line parallel to the initial plane can be used as another edge of the vertex, thereby establishing a first plane.
[0091] It should be noted that, when the wearable device is two devices, such as two wireless earphones, the position of the wearable device is the position of any one of the wireless earphones, or the midpoint of the line connecting the two wireless earphones.
[0092] For example, in combination with the above example 1, Figure 4 , which is a schematic diagram of an initial plane provided in an embodiment of the present application and a first plane parallel to the wearable device established after the user wears the wearable device and rotates it. Figure 4 Taking the wearable devices as two wireless headphones as an example, the above-mentioned initial plane 10 is parallel to the user's face and perpendicular to the ground plane. After the user wears the two wireless headphones and turns his head, the position of the right earplug is taken as a vertex A, and based on the vertex A, the rotation direction d and the rotation angle α, an edge x is determined, and then a line parallel to the initial plane is taken as the other edge y of the vertex A, thereby establishing the first plane 20.
[0093] In the embodiment of the present application, when the first position information includes one position information, the position point indicated by the position information is connected with the position point indicated by the second position information to obtain a first straight line. Similarly, for N second position information, N first straight lines can be obtained.
[0094] For example, taking the wearable device as a smart watch, the first location information is the location information of the smart watch, and the wearable device connects the location point indicated by the first location information with the location point indicated by the second location information of a connectable device to establish a first straight line.
[0095] In an embodiment of the present application, when the first position information includes two position information, the position points indicated by the two position information are connected to obtain a connecting line, and a perpendicular line passing through the position point indicated by the second position information is made as a first straight line.
[0096] Exemplarily, taking the wearable device as a wireless headset, the first location information includes location information of two wireless headsets, namely, location information of a left earbud and location information of a right earbud. The location point indicated by the location information of the left earbud and the location point indicated by the location information of the right earbud are connected to obtain a connecting line, and a perpendicular line through the location point indicated by the second location information is drawn as a first straight line.
[0097] It should be noted that, when the first position information includes two position information, the size of the first plane is limited by the distance between the position points indicated by the two position information, that is, the first plane is not an infinite plane. In this case, one point of the first straight line is the position point indicated by the second position information, and the other point may be on the connecting line or on the extension line of the connecting line, that is, the first straight line may intersect with the first plane or may not intersect with the first plane.
[0098] Step 302: The wearable device determines, based on the first plane and the N first straight lines, a connectable device corresponding to a first straight line perpendicular to the first plane among the N connectable devices as a first device.
[0099] In an embodiment of the present application, the wearable device selects a second straight line and a third straight line in the first plane that pass through the position point indicated by the first position information, and the second straight line intersects the third straight line. If a first straight line among the N first straight lines is perpendicular to both the second straight line and the third straight line, it can be determined that the first straight line is perpendicular to the first plane, and the connectable device corresponding to the first straight line is determined to be the first device.
[0100] Exemplarily, when the first location information includes two location information, the wearable device can determine the connecting line obtained by connecting the location points indicated by the two location information (for example, the location point indicated by the location information of the left earbud and the location point indicated by the location information of the right earbud) as the second straight line, and determine the straight line in the first plane that intersects with the second straight line and passes through the location point indicated by any one of the two location information as the third straight line.
[0101] In this way, the wearable device establishes a first plane parallel to itself, and establishes corresponding first straight lines according to the position information of the wearable device and the position information of each connectable device. When a first straight line is perpendicular to the first plane, it can be considered that the connectable device corresponding to the first straight line is the device that the wearable device is "facing" directly, and is the device that the user is facing directly, and it can be determined as the first device. That is, the user only needs to perform a simple rotation action, and the wearable device can quickly and accurately determine the device that the user needs the wearable device to connect to, which simplifies the user's operation process and improves the efficiency of establishing connections between devices.
[0102] Optionally, in the embodiment of the present application, the first parameter includes a sliding parameter, and the sliding parameter includes a sliding direction and a sliding distance of the wearable device by the user. Exemplarily, the step 102 can be implemented by the following steps 401 and 402.
[0103] Step 401: The wearable device determines a second parameter from at least one corresponding relationship based on a sliding direction and a sliding distance.
[0104] In the embodiment of the present application, each of the at least one corresponding relationship is a corresponding relationship between a sliding parameter and a parameter of the connectable device relative to the wearable device. The second parameter includes a first distance range and a first direction.
[0105] In the embodiment of the present application, the parameters of the connectable device relative to the wearable device include the distance range and direction of the connectable device relative to the wearable device.
[0106] In an embodiment of the present application, the above-mentioned at least one corresponding relationship can be set by the user according to actual needs, or can be set by default by the wearable device, and the embodiment of the present application does not limit this.
[0107] Exemplarily, the at least one corresponding relationship is shown in Table 1, and Table 1 includes multiple corresponding relationships.
[0108] Table 1
[0109]
[0110] Exemplarily, taking the sliding direction as the lower left and the sliding distance as 1 cm, it can be determined from the above Table 1 that the first direction is the lower left and the first distance range is 9.5 m-10 m.
[0111] Step 402: Based on the second parameter, the first location information, and the N second location information, the wearable device determines, as the first device, a connectable device among the N connectable devices whose direction relative to the wearable device is a first direction and whose distance from the wearable device is within a first distance range.
[0112] In an embodiment of the present application, the wearable device can determine the direction and distance of each connectable device relative to the wearable device based on the first location information and N second location information, and then determine the connectable device among the N connectable devices whose direction relative to the wearable device is the first direction and whose distance to the wearable device is within a first distance range as the first device.
[0113] Exemplarily, the wearable device can map the first location information and N second location information to a plane parallel to the ground plane, convert the first location information and N second location information into two-dimensional coordinates, and then determine the direction and distance of each connectable device relative to the wearable device.
[0114] For example, taking the example of three connectable devices around the wearable device, assuming that the two-dimensional coordinates obtained by converting the first position information are (0, 0), and the two-dimensional coordinates obtained by converting the three second position information are (-1, 0), (0, 2) and (3, 4) respectively, it can be determined that the direction of the first connectable device relative to the wearable device is the left and the distance is 1m, the direction of the second connectable device relative to the wearable device is above and the distance is 2m, and the direction of the third connectable device relative to the wearable device is the upper right and the distance is 5m.
[0115] Exemplarily, after determining the direction and distance of each connectable device relative to the wearable device, connectable devices whose direction relative to the wearable device is a first direction are preliminarily screened out from N connectable devices, and then the connectable devices whose distance to the wearable device is within a first distance range among the preliminarily screened connectable devices are determined as first devices.
[0116] For example, assuming that the first direction is the upper right, the first distance range is 3.5m-4m, there are 4 connectable devices around the wearable device, the first connectable device is in the left direction relative to the wearable device and the distance is 1m, the second connectable device is in the upper right direction relative to the wearable device and the distance is 3.7m, the third connectable device is in the upper direction relative to the wearable device and the distance is 5m, the fourth connectable device is in the upper right direction relative to the wearable device and the distance is 5m. The second and fourth connectable devices are preliminarily screened out according to the first direction, and the second connectable device can be determined as the first device by further screening according to the first distance range.
[0117] In this way, the user only needs to perform a simple sliding operation, and the wearable device can quickly and accurately determine the device to which the user needs the wearable device to connect based on the user's sliding direction and sliding distance, simplifying the user's operation process and thus improving the efficiency of establishing connections between devices.
[0118] Step 103: The wearable device establishes a connection between the wearable device and the first device.
[0119] Exemplarily, the wearable device may send a connection establishment request to the first device, and after receiving a connection confirmation message fed back by the first device, the connection between the wearable device and the first device is established.
[0120] In the connection establishment method provided in the embodiment of the present application, the wearable device can determine the first device from the N connectable devices based on the first parameter, the first location information of the wearable device and the N second location information corresponding to the N connectable devices, and then establish the connection between the wearable device and the first device. In this scheme, the wearable device can obtain the rotation parameter or sliding parameter of the wearable device by the user, that is, the wearable device can obtain the device that the user needs the wearable device to connect to according to the rotation or sliding operation performed by the user on the wearable device, that is, the user only needs to perform a simple rotation or sliding operation on the wearable device to trigger the wearable device to quickly determine the device that the user needs the wearable device to connect to, so that the wearable device locates the device that the user needs the wearable device to connect to from the multiple connectable devices according to its own location information and the location information of multiple connectable devices, and realizes the connection establishment between the devices, thereby simplifying the operation flow of the connection establishment process between the wearable device and the connectable device, and improving the efficiency of the connection establishment between the wearable device and the connectable device.
[0121] Optionally, in the embodiment of the present application, combined with Figure 1 ,like Figure 5 As shown, after executing step 103, the connection establishment method provided in the embodiment of the present application may further include the following steps 501 to 503.
[0122] Step 501: The wearable device receives a second input from a user.
[0123] In the embodiment of the present application, the second input is an input of a user to a touch area in the wearable device, or an input of a user to a rotation of the wearable device.
[0124] Optionally, in the embodiment of the present application, when the second input is the user's input to the touch area of the wearable device, the second input may include but is not limited to: the user touches the touch area of the wearable device through a touch device such as a finger or a stylus, or a specific gesture input by the user in the touch area of the wearable device, or other feasible input by the user in the touch area of the wearable device. The specific input can be determined according to actual use requirements and is not limited in the embodiment of the present application.
[0125] Exemplarily, the touch area in the wearable device is provided with a connection switching button, and the second input may be a user's touch input to the connection switching button in the touch area in the wearable device to trigger the wearable device to disconnect from the currently connected device, namely the first device.
[0126] Optionally, in an embodiment of the present application, when the above-mentioned second input is a rotation input of the wearable device by the user, the above-mentioned second input may include but is not limited to: a rotation input of the wearable device when the user wears the wearable device and rotates it at a rotation angle greater than a first threshold, or a rotation input of the wearable device when the user wears the wearable device and rotates it at a rotation speed less than a second threshold.
[0127] Step 502: The wearable device disconnects the wearable device from the first device in response to the second input.
[0128] Step 503: When the wearable device receives a connection establishment request from a third device among the N connectable devices, the wearable device establishes a connection between the wearable device and the third device.
[0129] The third device is a connectable device that is gazed at by the user as determined by eye tracking.
[0130] In an embodiment of the present application, the above-mentioned connection establishment request is used to instruct the wearable device to establish a connection with the third device.
[0131] Exemplarily, the connection establishment request may include identification information of the third device. For example, the connection establishment request may include identification information such as a Media Access Control (MAC) address and a device name of the third device.
[0132] In the embodiment of the present application, the N connectable devices are all equipped with an infrared eye tracking system. If the user requires the wearable device to switch to connect to a third device, the user will look at the third device, and the third device can determine that the user's gaze point is on the screen of the third device through the infrared eye tracking system.
[0133] In an embodiment of the present application, for a connectable device, when a user enters the visible range of the connectable device, the infrared eye tracking system of the connectable device is activated, and begins to capture infrared rays reflected by the user's eyeballs and generate an image. The position of the pupil center is determined from the image through an image processing algorithm, and then based on the position of the pupil center, the size and position of the connectable device, it is determined whether the pupil center is located on the screen of the connectable device, that is, whether the user is looking at the connectable device. If so, the connectable device sends a connection establishment request to the wearable device to establish a connection with the wearable device.
[0134] In this way, the user only needs to perform simple touch input and look at the connectable device to which the wearable device needs to be connected, so as to trigger the wearable device to switch the device connected to itself and establish a connection between the wearable device and other devices. The operation is simple and improves the efficiency of switching connected devices and establishing connections between devices.
[0135] Figure 6 1 is a flow chart of a connection establishment method provided in an embodiment of the present application. Taking the wearable device as a wireless headset as an example, the method may include the following steps 601-606.
[0136] Step 601: The user wears a wireless headset, and when the wireless headset is connected to an old device, the wireless headset receives a first input from the user.
[0137] For example, the first input is a touch input of a connection switch control of a wireless headset by a user.
[0138] Step 602: The wireless headset disconnects the old device in response to the first input.
[0139] Step 603: The user wears the wireless headset and turns his head. During the rotation of the wireless headset, the gyroscope is used to obtain the rotation direction and rotation angle.
[0140] Step 604: The wireless headset establishes a first plane parallel to the wireless headset according to the rotation direction, the rotation angle and the position information of the wireless headset.
[0141] Step 605: The wireless headset establishes N first straight lines according to its own location information and the location information of the N connectable devices.
[0142] Step 606: The wireless headset determines that the connectable device corresponding to the first straight line perpendicular to the first plane among the N first straight lines is a new device that the user requires the wireless headset to connect to, and establishes a connection between the wireless headset and the new device.
[0143] like Figure 7 , which is a schematic diagram of a connection establishment method provided in an embodiment of the present application. Figure 7 Taking the wearable device as a wireless headset as an example, there are four connectable devices near the wireless headset, namely device a, device b, device c and device d. After the user puts on the wireless headset, he presses the connection switch button of the wireless headset and turns his face toward the new device to which the wireless headset needs to be connected. The wireless headset determines that the new device the user's face is facing is device c based on the rotation direction, rotation angle, location information of the wireless headset and location information of the four connectable devices, and the wireless headset establishes a connection with device c.
[0144] In this way, the user only needs to perform two actions, clicking and turning the head, and the wearable device can accurately locate the new device the user is facing, that is, the new device to which the user needs to connect the wireless headphones, and switch from the old device to the new device, thereby improving the efficiency of interaction, and then improving the efficiency of connection switching and connection establishment between devices, thereby improving the user experience.
[0145] It should be noted that the specific implementation process of the above steps 601 to 606 can refer to the relevant description of the above embodiment. To avoid repetition, this embodiment will not be repeated here.
[0146] Figure 8 It is a flowchart of a connection establishment method provided according to an embodiment of the present application. Taking the wearable device as a wireless headset as an example, the method may include the following steps 701-705.
[0147] Step 701: The user wears a wireless headset, and when the wireless headset is connected to an old device, the wireless headset receives a first input from the user.
[0148] For example, the first input is a touch input of a connection switch control of a wireless headset by a user.
[0149] Step 702: The wireless headset disconnects from the old device in response to the first input, and obtains a sliding direction and a sliding distance according to a sliding operation of the user on the touch area.
[0150] Step 703: The wireless headset determines a first distance range and a first direction from a preset corresponding relationship according to the sliding direction and the sliding distance.
[0151] Step 704: The wireless headset determines directions and distances of the N connectable devices relative to the wireless headset based on its own location information and the location information of the N connectable devices.
[0152] Step 705: The wireless headset determines from the N connectable devices that a connectable device that is in a first direction relative to the wireless headset and is within a first distance range from the wireless headset is the device that the user requires the wireless headset to connect to, and establishes a connection between the wireless headset and the connectable device.
[0153] like Fig. 9 , which is a schematic diagram of a connection establishment method provided in an embodiment of the present application. Fig. 9 For example, if the wearable device is a wireless headset, there are 6 connectable devices near the wireless headset, namely, device a, device b, device c, device d, device e, and device f. The directions of these 6 devices relative to the wireless headset are upper left, upper, upper right, lower left, lower, and lower right. After the user puts on the wireless headset, he presses the connection switch control in the touch area of the wireless headset and slides the touch area to the lower right. The wireless headset determines that the connectable device in the lower right direction relative to the wireless headset is device f based on the sliding direction, and the wireless headset establishes a connection with device f.
[0154] In this way, the user only needs to slide on the touch area after clicking, and the wearable device can accurately locate the new device that matches the user's sliding direction, that is, the new device that the user needs the wearable device to connect to, and switch from the old device to the new device, thereby improving the efficiency of interaction, and then improving the efficiency of connection switching and connection establishment between devices, thereby improving the user experience.
[0155] It should be noted that the specific implementation process of the above steps 701 to 705 can refer to the relevant description of the above embodiment. To avoid repetition, this embodiment will not be repeated here.
[0156] It should be noted that the above-mentioned method embodiments, or various possible implementation methods in each method embodiment, can be executed separately, or any two or more can be executed in combination with each other. The specific implementation method can be determined according to actual usage requirements, and the embodiments of the present application do not impose any restrictions on this.
[0157] The connection establishment method provided in the embodiment of the present application may be executed by a connection establishment device. In the embodiment of the present application, the connection establishment method executed by the connection establishment device is taken as an example to illustrate the connection establishment device provided in the embodiment of the present application.
[0158] Fig.10 : is a schematic diagram of the structure of a connection establishment device provided in an embodiment of the present application, the connection establishment device comprising:
[0159] An acquisition module 801 is used to acquire a first parameter, where the first parameter includes a rotation parameter or a sliding parameter of the wearable device by the user;
[0160] A determination module 802 is used to determine a first device from N connectable devices based on the first parameter obtained by the acquisition module, the first location information of the wearable device, and N second location information corresponding to the N connectable devices, where N is an integer greater than 1;
[0161] The establishing module 803 is used to establish a connection between the wearable device and the first device determined by the determining module.
[0162] Optionally, in an embodiment of the present application, the first parameter includes a rotation parameter, and the rotation parameter includes a rotation direction and a rotation angle of the wearable device relative to an initial plane;
[0163] The determination module 802 is specifically configured to:
[0164] A first plane is established based on the rotation direction, the rotation angle and the first position information, and N first straight lines are established based on the first position information and the N second position information, each first straight line corresponding to one second position information;
[0165] Based on the first plane and the N first straight lines, a connectable device corresponding to a first straight line perpendicular to the first plane among the N connectable devices is determined as a first device.
[0166] Optionally, in the embodiment of the present application, the first parameter includes a sliding parameter, and the sliding parameter includes a sliding direction and a sliding distance of the wearable device by the user;
[0167] The determination module 802 is specifically configured to:
[0168] Based on the sliding direction and the sliding distance, determining a second parameter from at least one corresponding relationship, each corresponding relationship being a corresponding relationship between a sliding parameter and a parameter of the connectable device relative to the wearable device, the second parameter comprising a first distance range and a first direction;
[0169] Based on the second parameter, the first location information and the N second location information, a connectable device among the N connectable devices whose direction relative to the wearable device is a first direction and whose distance to the wearable device is within a first distance range is determined as a first device.
[0170] Optionally, in the embodiment of the present application, combined with Fig.10 ,like Fig.11 As shown, the device also includes:
[0171] The receiving module 804 is used to receive a first input from a user before the acquiring module acquires the first parameter, when the wearable device is connected to the second device, where the first input is an input from the user to a touch area in the wearable device, or an input from the user to rotate the wearable device;
[0172] The execution module 805 is used to disconnect the wearable device from the second device in response to the first input received by the receiving module.
[0173] Optionally, in the embodiment of the present application, the device further includes:
[0174] The receiving module 804 is used to receive a second input from the user after the establishment module establishes a connection between the wearable device and the first device determined by the determination module, where the second input is an input from the user to a touch area in the wearable device, or an input from the user to rotate the wearable device;
[0175] An execution module 805 is configured to disconnect the wearable device from the first device in response to a second input received by the receiving module;
[0176] The establishing module 803 is also used to establish a connection between the wearable device and the third device when a connection establishment request from a third device among the N connectable devices is received, where the third device is a connectable device that the user is looking at as determined by eye tracking.
[0177] The connection establishment device provided in the embodiment of the present application can determine the first device from the N connectable devices based on the first parameter, the first location information of the wearable device and the N second location information corresponding to the N connectable devices, and then establish the connection between the wearable device and the first device. In this scheme, the connection establishment device can obtain the rotation parameter or sliding parameter of the wearable device by the user, that is, the connection establishment device can obtain the device that the user needs the wearable device to connect to according to the rotation or sliding operation performed by the user on the wearable device, that is, the user only needs to perform a simple rotation or sliding operation on the wearable device to trigger the wearable device to quickly determine the device that the user needs the wearable device to connect to, so that the wearable device locates the device that the user needs the wearable device to connect to from the multiple connectable devices according to its own location information and the location information of multiple connectable devices, and realizes the connection establishment between the devices, thereby simplifying the operation process of the connection establishment process between the wearable device and the connectable device, and improving the efficiency of the connection establishment between the wearable device and the connectable device.
[0178] The connection establishment device in the embodiment of the present application can be an electronic device, or a component in the electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal, or it can be other devices other than a terminal. Exemplarily, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted electronic device, a mobile Internet device, an augmented reality / virtual reality device, a robot, a wearable device, a super mobile personal computer, a netbook or a personal digital assistant, etc., and can also be a server, a network attached storage (Network Attached Storage, NAS), a personal computer (personal computer, PC), a television (television, TV), a teller machine or a self-service machine, etc., which is not specifically limited in the embodiment of the present application.
[0179] The connection establishment device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.
[0180] The connection establishment device provided in the embodiment of the present application can implement the various processes implemented by the various embodiments of the above-mentioned connection establishment method. To avoid repetition, they will not be described here.
[0181] Alternatively, if Fig.12As shown, an embodiment of the present application also provides an electronic device 900, including a processor 901 and a memory 902, wherein the memory 902 stores programs or instructions that can be executed on the processor 901, and when the program or instructions are executed by the processor 901, the various steps of the above-mentioned connection establishment method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, they are not described here.
[0182] It should be noted that the electronic device in the embodiment of the present application includes the mobile electronic device and the non-mobile electronic device described above. For example, the electronic device may be the wearable device described in the embodiment of the present application.
[0183] Fig.13 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of the present application.
[0184] The electronic device 1000 includes but is not limited to: a radio frequency unit 1001, a network module 1002, an audio output unit 1003, an input unit 1004, a sensor 1005, a display unit 1006, a user input unit 1007, an interface unit 1008, a memory 1009, and a processor 1010 and other components.
[0185] Those skilled in the art will appreciate that the electronic device 1000 may also include a power source (such as a battery) for supplying power to each component, and the power source may be logically connected to the processor 1010 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Fig.13 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.
[0186] The processor 1010 is configured to:
[0187] Acquire a first parameter, where the first parameter includes a rotation parameter or a sliding parameter of the wearable device by the user;
[0188] Determine a first device from the N connectable devices based on the first parameter, the first location information of the wearable device, and the N second location information corresponding to the N connectable devices, where N is an integer greater than 1;
[0189] A connection is established between the wearable device and the first device.
[0190] Optionally, the first parameter includes a rotation parameter, and the rotation parameter includes a rotation direction and a rotation angle of the wearable device relative to the initial plane; the processor 1010 is specifically configured to:
[0191] A first plane is established based on the rotation direction, the rotation angle and the first position information, and N first straight lines are established based on the first position information and the N second position information, each first straight line corresponding to one second position information;
[0192] Based on the first plane and the N first straight lines, a connectable device corresponding to a first straight line perpendicular to the first plane among the N connectable devices is determined as a first device.
[0193] Optionally, the first parameter includes a sliding parameter, and the sliding parameter includes a sliding direction and a sliding distance of the wearable device by the user;
[0194] The processor 1010 is specifically configured to:
[0195] Based on the sliding direction and the sliding distance, determining a second parameter from at least one corresponding relationship, each corresponding relationship being a corresponding relationship between a sliding parameter and a parameter of the connectable device relative to the wearable device, the second parameter comprising a first distance range and a first direction;
[0196] Based on the second parameter, the first location information and the N second location information, a connectable device among the N connectable devices whose direction relative to the wearable device is a first direction and whose distance to the wearable device is within a first distance range is determined as a first device.
[0197] Optionally, the processor 1010 is also used to, before obtaining the first parameter, receive a first input from the user when the wearable device is connected to the second device, the first input being an input by the user to a touch area in the wearable device, or an input by the user to a rotation of the wearable device; and, in response to the first input, disconnect the wearable device from the second device.
[0198] Optionally, the processor 1010 is further used to receive a second input from the user after establishing a connection between the wearable device and the first device determined by the determination module, the second input being an input from the user to a touch area in the wearable device, or being an input from the user to a rotation of the wearable device; and, in response to the second input, disconnect the wearable device from the first device; and, upon receiving a connection establishment request from a third device among N connectable devices, establish a connection between the wearable device and the third device, the third device being a connectable device that the user is looking at as determined by eye tracking.
[0199] In the embodiment of the present application, the wearable device can obtain the rotation parameter or sliding parameter of the wearable device by the user, that is, the wearable device can obtain the device that the user requires the wearable device to be connected to according to the rotation or sliding operation performed by the user on the wearable device. In other words, the user only needs to perform a simple rotation or sliding operation on the wearable device to trigger the wearable device to quickly determine the device that the user requires the wearable device to be connected to, so that the wearable device locates the device that the user requires the wearable device to be connected to from multiple connectable devices according to its own position information and the position information of multiple connectable devices, and establishes a connection between the devices. Therefore, the operation process of the connection establishment process between the wearable device and the connectable device is simplified, and the efficiency of the connection establishment between the wearable device and the connectable device is improved.
[0200] It should be understood that in the embodiment of the present application, the input unit 1004 may include a graphics processor (Graphics Processing Unit, GPU) 10041 and a microphone 10042, and the graphics processor 10041 processes the image data of the static picture or video obtained by the image capture device (such as a camera) in the video capture mode or the image capture mode. The display unit 1006 may include a display panel 10061, and the display panel 10061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 1007 includes a touch panel 10071 and at least one of other input devices 10072. The touch panel 10071 is also called a touch screen. The touch panel 10071 may include two parts: a touch detection device and a touch controller. Other input devices 10072 may include, but are not limited to, a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.
[0201] The memory 1009 can be used to store software programs and various data. The memory 1009 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 1009 may include a volatile memory or a non-volatile memory, or the memory 1009 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory 109 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.
[0202] The processor 1010 may include one or more processing units; optionally, the processor 1010 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 1010.
[0203] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the above-mentioned connection establishment method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0204] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.
[0205] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned connection establishment method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0206] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0207] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned connection establishment method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0208] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0209] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.
[0210] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
Claims
1. A connection establishment method, applied to a wearable device, characterized in that: The method comprises: Acquire a first parameter, where the first parameter includes a rotation parameter or a sliding parameter of the wearable device by a user; Determine a first device from the N connectable devices based on the first parameter, the first location information of the wearable device, and N second location information corresponding to the N connectable devices, where N is an integer greater than 1; Establishing a connection between the wearable device and the first device.
2. The method according to claim 1, characterized in that: The first parameter includes the rotation parameter, and the rotation parameter includes a rotation direction and a rotation angle of the wearable device relative to an initial plane; The determining a first device from the N connectable devices based on the first parameter, the first location information of the wearable device, and the N second location information respectively corresponding to the N connectable devices, comprises: A first plane is established based on the rotation direction, the rotation angle and the first position information, and N first straight lines are established based on the first position information and the N second position information, each first straight line corresponding to one second position information; Based on the first plane and the N first straight lines, a connectable device corresponding to a first straight line perpendicular to the first plane among the N connectable devices is determined as the first device.
3. The method according to claim 1, characterized in that The first parameter includes the sliding parameter, and the sliding parameter includes a sliding direction and a sliding distance of the wearable device by the user; The determining a first device from the N connectable devices based on the first parameter, the first location information of the wearable device, and the N second location information respectively corresponding to the N connectable devices, comprises: Based on the sliding direction and the sliding distance, determining a second parameter from at least one corresponding relationship, each corresponding relationship being a corresponding relationship between a sliding parameter and a parameter of a connectable device relative to the wearable device, the second parameter comprising a first distance range and a first direction; Based on the second parameter, the first location information and the N second location information, a connectable device among the N connectable devices whose direction relative to the wearable device is the first direction and whose distance to the wearable device is within the first distance range is determined as the first device.
4. The method according to any one of claims 1 to 3, characterized in that Before obtaining the first parameter, the method further includes: When the wearable device is connected to the second device, receiving a first input from a user, where the first input is an input from the user to a touch area of the wearable device, or an input from the user to rotate the wearable device; In response to the first input, the wearable device is disconnected from the second device.
5. The method according to any one of claims 1 to 3, characterized in that After establishing the connection between the wearable device and the first device, the method further includes: receiving a second input from a user, where the second input is an input from the user to a touch area in the wearable device, or an input from the user to rotate the wearable device; In response to the second input, disconnecting the wearable device from the first device; Upon receiving a connection establishment request from a third device among the N connectable devices, a connection is established between the wearable device and the third device, where the third device is a connectable device that the user is looking at as determined by eye tracking.
6. A connection establishment device, characterized in that: The device comprises: An acquisition module, configured to acquire a first parameter, wherein the first parameter includes a rotation parameter or a sliding parameter of the wearable device by a user; a determination module, configured to determine a first device from the N connectable devices based on the first parameter acquired by the acquisition module, the first location information of the wearable device, and N second location information respectively corresponding to the N connectable devices, where N is an integer greater than 1; An establishing module is used to establish a connection between the wearable device and the first device determined by the determining module.
7. The device according to claim 6, characterized in that The first parameter includes the rotation parameter, and the rotation parameter includes a rotation direction and a rotation angle of the wearable device relative to an initial plane; The determination module is specifically used for: A first plane is established based on the rotation direction, the rotation angle and the first position information, and N first straight lines are established based on the first position information and the N second position information, each first straight line corresponding to one second position information; Based on the first plane and the N first straight lines, a connectable device corresponding to a first straight line perpendicular to the first plane among the N connectable devices is determined as the first device.
8. The device according to claim 6, characterized in that The first parameter includes the sliding parameter, and the sliding parameter includes a sliding direction and a sliding distance of the wearable device by the user; The determination module is specifically used for: Based on the sliding direction and the sliding distance, determining a second parameter from at least one corresponding relationship, each corresponding relationship being a corresponding relationship between a sliding parameter and a parameter of a connectable device relative to the wearable device, the second parameter comprising a first distance range and a first direction; Based on the second parameter, the first location information and the N second location information, a connectable device among the N connectable devices whose direction relative to the wearable device is the first direction and whose distance to the wearable device is within the first distance range is determined as the first device.
9. The device according to any one of claims 6 to 8, characterized in that The device also includes: a receiving module, configured to receive a first input from a user before the acquiring module acquires the first parameter, when the wearable device is connected to the second device, wherein the first input is an input from the user to a touch area in the wearable device, or an input from the user to rotate the wearable device; An execution module is used to disconnect the wearable device from the second device in response to the first input received by the receiving module.
10. The device according to any one of claims 6 to 8, characterized in that The device also includes: a receiving module, configured to receive a second input from a user after the establishing module establishes a connection between the wearable device and the first device determined by the determining module, wherein the second input is an input from the user to a touch area in the wearable device, or an input from the user to rotate the wearable device; an execution module, configured to disconnect the wearable device from the first device in response to the second input received by the receiving module; The establishment module is further used to establish a connection between the wearable device and the third device when a connection establishment request from a third device among the N connectable devices is received, wherein the third device is a connectable device that the user is looking at as determined by eye tracking.
11. An electronic device, characterized in that: The method comprises a processor and a memory, wherein the memory stores a program or instruction that can be run on the processor, and when the program or instruction is executed by the processor, the steps of the connection establishment method according to any one of claims 1 to 5 are implemented.
