Device connection method, device, hardware device and computer readable storage medium
By pre-stored valid information and authentication information of the hardware device, the third-party device directly establishes a communication connection of the first connection method during the first connection, solving the problem of inefficient connection in the prior art and achieving fast and convenient connection operations.
Patent Information
- Application Number
- CN202080074810.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-11-05
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2040-11-05
AI Technical Summary
In the prior art, the connection efficiency of hardware devices is low, and users need to manually select the connection method, resulting in cumbersome operation and inefficient efficiency.
By pre-stored valid information and authentication information of the hardware device, the third-party device and the hardware device directly use the pre-stored information to directly establish a communication connection in the first connection method during the first connection, thereby improving the connection efficiency.
It realizes fast and convenient connection between third-party devices and hardware devices, improves connection efficiency, and reduces the complexity of user operations.
Smart Images

Figure CN114710978B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of network technology, and in particular relates to a device connection method, device, hardware device and computer-readable storage medium. Background Art
[0002] At present, the application of hardware devices is becoming more and more widespread. In order to facilitate users to control hardware devices, hardware devices often provide multiple connection methods for users to use. In the case of multiple connection methods, how to connect to the hardware devices conveniently and efficiently based on these multiple connection methods has become a problem of widespread concern. In the prior art, the connection is often established by manual selection. However, the connection efficiency of this method is low. Summary of the invention
[0003] The present invention provides a device connection method, apparatus, hardware device and computer-readable storage medium to solve the problem of low connection efficiency.
[0004] In order to solve the above-mentioned technical problems, the present invention is achieved as follows:
[0005] In a first aspect, an embodiment of the present invention provides a device connection method, which is applied to a third-party device, and includes:
[0006] When the third-party device communicates with the hardware device for the first time in the first connection mode, the third-party device is connected to the hardware device according to the pre-stored valid information of the hardware device; wherein the valid information is obtained in the following manner:
[0007] When the third-party device is communicatively connected with the hardware device in a second connection mode, valid information of the hardware device is obtained through the second connection mode; wherein the valid information is associated with the first connection mode.
[0008] In a second aspect, an embodiment of the present invention provides another device connection method, which is applied to a hardware device and includes:
[0009] When the hardware device communicates with the third-party device for the first time in the first connection mode, the hardware device connects with the third-party device according to the pre-stored authentication information of the third-party device; wherein the authentication information is obtained in the following manner:
[0010] When the hardware device is communicatively connected with the third-party device in a second connection mode, the authentication information of the third-party device is obtained through the second connection mode.
[0011] In a third aspect, an embodiment of the present invention provides another device connection method, which is applied to the communication connection between a third-party device and a target drone, wherein the drone is equipped with a camera, and the camera is used to collect original images; the method includes:
[0012] When the third-party device enters the preset mode, detect a connectable device around the third-party device; the connectable device is a drone device that can be connected to the hardware device in a first connection mode; the first connection mode is used to enable the third-party device and the drone to be directly connected, and enable the third-party device to obtain the original image at a high speed;
[0013] Determining the target drone from the connectable devices according to signal parameters of the broadcast signals sent by each of the connectable devices;
[0014] A communication connection is established with the target UAV according to the first connection mode.
[0015] In a fourth aspect, an embodiment of the present invention provides a device connection apparatus, the device is applied to a third-party device, and the device includes a memory and a processor;
[0016] The memory is used to store program code;
[0017] The processor calls the program code, and when the program code is executed, is used to perform the following operations:
[0018] When the third-party device communicates with the hardware device for the first time in the first connection mode, the third-party device is connected to the hardware device according to the pre-stored valid information of the hardware device; wherein the valid information is obtained in the following manner:
[0019] When the third-party device is communicatively connected with the hardware device in a second connection mode, valid information of the hardware device is obtained through the second connection mode; wherein the valid information is associated with the first connection mode.
[0020] In a fifth aspect, an embodiment of the present invention provides another device connection apparatus, wherein the method is applied to a hardware device, and the method apparatus includes a memory and a processor;
[0021] The memory is used to store program code;
[0022] The processor calls the program code, and when the program code is executed, is used to perform the following operations:
[0023] When the hardware device communicates with the third-party device for the first time in the first connection mode, the hardware device connects with the third-party device according to the pre-stored authentication information of the third-party device; wherein the authentication information is obtained in the following manner:
[0024] When the hardware device is communicatively connected with the third-party device in a second connection mode, the authentication information of the third-party device is obtained through the second connection mode.
[0025] In a sixth aspect, an embodiment of the present invention provides a device connection apparatus, characterized in that the apparatus is applied to a communication connection between a third-party device and a target drone, the drone is equipped with a camera, and the camera is used to collect original images; the apparatus includes a memory and a processor;
[0026] The memory is used to store program code;
[0027] The processor calls the program code, and when the program code is executed, is used to perform the following operations:
[0028] When the third-party device enters the preset mode, detect a connectable device around the third-party device; the connectable device is a drone device that can be connected to the hardware device in a first connection mode; the first connection mode is used to enable the third-party device and the drone to be directly connected, and enable the third-party device to obtain the original image at a high speed;
[0029] Determining the target drone from the connectable devices according to signal parameters of the broadcast signals sent by each of the connectable devices;
[0030] A communication connection is established with the target UAV according to the first connection mode.
[0031] In a seventh aspect, an embodiment of the present invention provides a hardware device, which is used to implement the method described in the second aspect above.
[0032] In an eighth aspect, an embodiment of the present invention provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the device connection method described in any of the above aspects is implemented.
[0033] In the embodiment of the present invention, when the third-party device and the hardware device are connected in communication with each other in the second connection mode, valid information associated with the first connection mode is obtained through the second connection mode. When the third-party device and the hardware device are connected in communication with each other in the first connection mode for the first time, since the valid information associated with the first connection mode is obtained and stored in advance, when the third-party device and the hardware device are connected in communication with each other in the first connection mode, the third-party device can directly establish a connection with the hardware device based on the valid information pre-stored internally, thereby improving the connection efficiency to a certain extent. BRIEF DESCRIPTION OF THE DRAWINGS
[0034] Figure 1 is a flowchart of the steps of a device connection method provided by an embodiment of the present invention;
[0035] Figure 2 This is a schematic diagram of prompt information provided by an embodiment of the present invention;
[0036] Figure 3 is another schematic diagram of prompt information provided by an embodiment of the present invention;
[0037] Figure 4 is a schematic diagram of an interface provided by an embodiment of the present invention;
[0038] Figure 5 is a detection schematic diagram provided by an embodiment of the present invention;
[0039] Figure 6 is a flowchart of another device connection method provided by an embodiment of the present invention;
[0040] Figure 7 is a flowchart of the steps of another device connection method provided by an embodiment of the present invention;
[0041] Figure 8 is another interface schematic diagram provided by an embodiment of the present invention;
[0042] Fig. 9 This is another interface schematic diagram provided by an embodiment of the present invention;
[0043] Fig.10 This is another interface schematic diagram provided by an embodiment of the present invention;
[0044] Fig.11 This is another interface schematic diagram provided by an embodiment of the present invention;
[0045] Fig.12 is a block diagram of a device connection apparatus provided by an embodiment of the present invention;
[0046] Fig.13 is a block diagram of another device connection apparatus provided by an embodiment of the present invention;
[0047] Fig.14 is a block diagram of another device connection apparatus provided by an embodiment of the present invention;
[0048] Fig.15 A block diagram of a computing and processing device provided by an embodiment of the present invention;
[0049] Fig.16 A block diagram of a portable or fixed storage unit provided in accordance with an embodiment of the present invention. DETAILED DESCRIPTION
[0050] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0051] First, an application scenario involved in an embodiment of the present invention is described. In a scenario where a third-party device establishes a connection with a hardware device for the first time, the third-party device needs to establish a communication connection with the hardware device in the connection mode based on valid information associated with the connection mode. For example, when a third-party device establishes a communication connection with a hardware device in a first connection mode for the first time, the third-party device needs to establish a communication connection with the hardware device in the first connection mode based on valid information associated with the first connection mode of the hardware device. Since the process of a third-party device obtaining valid information from the outside is often more complicated, it will lead to lower connection efficiency to a certain extent. In this regard, an embodiment of the present invention provides a device connection method to improve connection efficiency.
[0052] The following is a detailed description of the device connection method.
[0053] Figure 1 is a flowchart of a device connection method provided by an embodiment of the present invention. The method can be applied to third-party devices, such as Figure 1 As shown, the method may include:
[0054] Step 101. When the third-party device is communicated with the hardware device for the first time in a first connection mode, the third-party device is connected to the hardware device according to the pre-stored valid information of the hardware device; wherein the valid information is obtained in the following manner: when the third-party device is communicated with the hardware device in a second connection mode, the valid information of the hardware device is obtained through the second connection mode; wherein the valid information is associated with the first connection mode.
[0055] In an embodiment of the present invention, the hardware device may be an intelligent hardware device such as a drone, an unmanned vehicle, a handheld gimbal, etc. A third-party device refers to a device from a different manufacturer than the hardware device. A third-party device may be a mobile device such as a mobile phone or a tablet computer. An application (Application, APP) corresponding to the hardware device may be installed on the third-party device. For example, interaction with the hardware device may be achieved based on the APP installed on the third-party device. The first connection mode and the second connection mode may be connection modes provided by the hardware device, and the specific types of the first connection mode and the second connection mode may be determined by the specific type of the hardware device, and the connection modes provided by different hardware devices may be different.
[0056] Furthermore, when the third-party device is connected to the hardware device in a communication manner in the second connection mode, since the two have already been connected in a communication manner, the valid information can be conveniently obtained and pre-stored in the third-party device through the communication connection established in the second connection mode in this manner for subsequent use. Among them, the specific type of valid information can be determined by the specific type of the first connection mode, and the valid information corresponding to different first connection modes can be different. Accordingly, when the third-party device is connected to the hardware device in a communication manner in the first connection mode for the first time, the pre-stored valid information can be directly read from the inside, and the communication connection in the first connection mode can be established based on the valid information. It should be noted that when the third-party device and the hardware device are not connected in a communication manner in the first connection mode for the first time, they can also be directly connected to the hardware device based on the pre-stored valid information, and the embodiments of the present invention are not limited to this.
[0057] In summary, the device connection method provided by the embodiment of the present invention obtains valid information associated with the first connection mode through the second connection mode when the third-party device and the hardware device are connected in communication with each other in the second connection mode. When the third-party device and the hardware device are connected in communication with each other in the first connection mode for the first time, since the valid information associated with the first connection mode is obtained and stored in advance, when the third-party device and the hardware device are connected in communication with each other in the first connection mode, the third-party device can directly establish a connection with the hardware device based on the valid information pre-stored internally, thereby improving the connection efficiency to a certain extent.
[0058] Optionally, in one implementation of the embodiment of the present invention, the third-party device can enter the first connection mode in the following manner: when the communication connection of the second connection mode is converted from the first preset state to the second preset state, the second connection mode is switched to the first connection mode; or, when a switching instruction from the user is received, the second connection mode is switched to the first connection mode; or, when a connection instruction to directly enter the first connection mode is received, a communication connection is established in the first connection mode.
[0059] In an embodiment of the present invention, the third-party device entering the first connection mode may refer to the third-party device entering a mode of communication connection in the first connection mode. After the third-party device enters the first connection mode, it can establish a communication connection with the hardware device in accordance with the first connection mode. Exemplarily, the first connection mode is a mode in which the third-party device and the hardware device are directly connected. Further, in an implementation mode, the first connection mode in the embodiment of the present invention may include one or more of Bluetooth connection, Wireless Fidelity (Wireless Fidelity, Wi-Fi) network connection or Bluetooth Wi-Fi combined link. Since the transmission speed of Bluetooth connection and Wi-Fi network connection is often faster, using Bluetooth connection and Wi-Fi network connection as the first connection mode can ensure the transmission efficiency with the hardware device to a certain extent. The second connection mode may include the third-party device connecting to the hardware device through a remote control device; wherein, the remote control device connecting to the hardware device as the second connection mode can more conveniently control the hardware device to perform various tasks. Among them, the remote control device can be a remote controller paired with the hardware device, and the remote control device can be connected to the hardware device through a software defined radio (Software Defined Radio, SDR), and the hardware device can be controlled by the remote control device. The first preset state may include that the remote control device is normally connected to the hardware device and the remote control device is normally connected to the third-party device, and the second preset state may include that the remote control device is disconnected from the hardware device, the connection is unstable, or an abnormality occurs. The second preset state also includes that the remote control device is disconnected from the third-party device, the connection is unstable, or an abnormality occurs.
[0060] Below, taking the hardware device as a drone, the third-party device as a mobile phone, and the remote control device as a remote control as an example, the first preset state and the second preset state are explained. In the second connection mode, the drone and the remote control are remotely connected, and the remote control and the mobile phone are connected via a wire. The first preset state includes the normal connection between the remote control and the drone and the normal connection between the remote control and the mobile phone. The second preset state may include the disconnection between the remote control and the drone, the unstable connection, or the abnormality. The second preset state also includes the disconnection between the remote control and the mobile phone, the unstable connection, or the abnormality.
[0061] In actual application scenarios, if the remote control device is normally connected to the hardware device, it can be explained to a certain extent that the user is currently in a state where the remote control device needs to be used to control the hardware device. Further, if the communication connection of the second connection mode is converted from the first preset state to the second preset state, that is, the remote control device is disconnected from the hardware device, the connection is unstable or an abnormality occurs. In this case, the third-party device often needs to establish a connection in other connection modes to determine that it enters the first connection mode. Accordingly, when the communication connection of the second connection mode is converted from the first preset state to the second preset state, it can be considered that the user has a greater probability of establishing a connection in the first connection mode in the current use scenario, and therefore, the second connection mode can be switched to the first connection mode. For example, the first connection mode corresponds to a high-speed download mode based on a WIFI connection. Assume that the remote control device is connected to a third-party device (such as a mobile phone) respectively, and the remote control device and the drone are connected in an SDR manner, and the remote control device and the third-party device are wired. The user can control the drone to perform aerial photography tasks by manipulating the remote control device, and the remote control device receives the compressed image sent by the drone, and the remote control device forwards it to the third-party device for real-time display. When the SDR connection between the remote control device and the drone is disconnected, the third-party device will automatically enter the high-speed download mode based on the WIFI connection. In this case, the first connection mode can be directly entered, so that the third-party device and the drone are connected via the Wi-Fi network, thereby facilitating the subsequent transmission of uncompressed original images to the third-party device.
[0062] Furthermore, the switching instruction may be sent by the user when the user needs to switch the second connection mode to the first connection mode, and the switching instruction may be sent through a switching option provided by a third-party device. For example, the third-party device may display a switching button, and the user may click the switching button when the user needs to switch the second connection mode to the first connection mode, thereby inputting a switching instruction to the third-party device. Accordingly, after receiving the switching instruction, the third-party device may determine that the user currently needs to use the first connection mode to connect to the hardware device, and therefore may switch from the second connection mode to the first connection mode.
[0063] Furthermore, the connection instruction for directly entering the first connection mode may be sent by the user when the user needs to directly enter the first connection mode, and the connection instruction may be sent through a connection option provided by the third-party device. For example, the third-party device may display a connection button, and the user may click the connection button when the user needs to directly enter the first connection mode, thereby inputting a connection instruction to the third-party device. Accordingly, after receiving the connection instruction, the third-party device may directly enter the first connection mode, that is, perform a communication connection in the first connection mode.
[0064] In an embodiment of the present invention, by actively entering the first connection mode when the communication connection of the second connection mode is converted from the first preset state to the second preset state, the first connection mode can be conveniently entered without waiting for user operation, thereby improving the efficiency of entering the first connection mode to a certain extent. Entering the first connection mode upon receiving a switching instruction or a connection instruction sent by the user can improve the flexibility of user control and avoid performing unnecessary operations to enter the first connection mode, thereby saving operating resources to a certain extent and being more in line with the user's experience. For example, after completing an aerial photography task, a general user needs to download high-definition materials to a third-party device (such as a user's personal mobile phone or personal computer). If the original method of forwarding through a remote control is still used, the download rate is relatively low, and the third-party device and the remote control device need to be connected, which is cumbersome to operate. Therefore, through this direct switching method, while reducing user operations, it also meets the overall needs of users.
[0065] Optionally, in an implementation of the embodiment of the present invention, before connecting with the hardware device according to the pre-stored valid information of the hardware device, the following steps may also be performed:
[0066] Step A: displaying first connection prompt information; the first connection prompt information is used to indicate whether to connect to the hardware device in the first connection mode.
[0067] In this step, the first connection prompt information may include the device information of the hardware device, so that the user can confirm whether to connect to the hardware device in the first connection mode based on the first connection prompt information. For example, the device information may be the device name, Figure 2 is a schematic diagram of a prompt information provided by an embodiment of the present invention, such as Figure 2 As shown, the first connection prompt information 01 includes the device name "Xiaobai's Aerial Photography Plane" and the connection option 01a. Step B: if a first operation for the first connection prompt information is received, the operation of connecting with the hardware device according to the pre-stored valid information of the hardware device is executed.
[0068] In this step, the first operation may be an operation that indicates confirmation of connection with the hardware device in the first connection mode. The specific operation mode of the first operation may be set according to actual needs. For example, the first operation may be operations such as clicking, sliding, and long pressing. For example, the first operation may be a click operation on the connection option in the first connection prompt information. If the first operation is received, it may be considered that the user needs to connect to the hardware device in the first connection mode, and thus the connection operation may be performed accordingly.
[0069] It should be noted that after the user clicks on the connection option, the third-party device may also display information about the current connection status to the user. For example, Figure 3 is another schematic diagram of prompt information provided by an embodiment of the present invention, such as Figure 3 As shown, during the connection process, "Connecting" can be displayed in the connection option 01a. Furthermore, after the connection is successful, relevant information of the hardware device, such as power information, can also be displayed. For example, Figure 4 is a schematic diagram of an interface provided by an embodiment of the present invention, such as Figure 4 As shown, the interface may display the power level "100%" and an album viewing option 01b for viewing the hardware device.
[0070] Step C: If a second operation is received for the first connection prompt information, a temporary shielding operation is performed on the hardware device.
[0071] In this step, the second operation may be an operation that represents the rejection of the first connection method to connect to the hardware device, and the specific operation method of the second operation may be set according to actual needs. For example, the second operation may be a sliding operation on the first connection prompt information. Alternatively, a cancel option may also be displayed, and the second operation may be a click operation on the cancel option. Accordingly, if the second operation is received, it may be considered that the user does not currently need to connect to the hardware device. For example, when the user is using a third-party device to perform other operations, such as using a third-party device to chat, the user may not need to connect to the hardware device temporarily and does not want to be disturbed by the connection prompt information. Therefore, a temporary shielding operation may be performed on the hardware device.
[0072] In the embodiment of the present invention, by displaying the first connection prompt information before connecting with the hardware device, the user performs the first operation in response to the first connection prompt information, that is, the user ensures that the hardware device is to be connected, and then performs the operation of connecting with the hardware device according to the pre-stored valid information of the hardware device, thereby avoiding the probability of connecting to the wrong device to a greater extent and improving the connection effect. At the same time, when the user does not need to connect to the hardware device at present, the user can perform the second operation on the first connection prompt information to implement the temporary shielding operation on the hardware device, thereby improving the operation efficiency of temporarily shielding the hardware device to a certain extent.
[0073] Optionally, the operation of performing a temporary shielding operation on the hardware device in the embodiment of the present invention may be implemented by the following sub-steps:
[0074] Step C1: Obtain the current startup times and device identification of the hardware device from the broadcast signal of the hardware device.
[0075] In the embodiment of the present invention, when each device sends a broadcast signal, the current startup times and device identification of the device can be added to the broadcast signal. Accordingly, in this step, the third-party device can parse the broadcast signal of the hardware device and extract the current startup times and device identification of the hardware device.
[0076] Step C2: Save the current startup times and device identification of the hardware device.
[0077] In this step, the third-party device can save the current number of startup times and device identification obtained into a preset blacklist to temporarily block the hardware device.
[0078] In the embodiment of the present invention, by obtaining the current startup times and device identification of the hardware device from the broadcast signal and saving the current startup times and device identification, the hardware device can be conveniently temporarily shielded, thereby improving the shielding efficiency to a certain extent.
[0079] Furthermore, the embodiment of the present invention may further perform the following steps after performing the temporary shielding operation on the hardware device:
[0080] Step D: After performing a temporary shielding operation on the hardware device, a new device identification and a new startup count are received again.
[0081] In this step, the device identification and the number of startup times of the hardware device that has been communicatively connected in the second connection mode are reacquired to obtain a new device identification and a new number of startup times.
[0082] Step E: When the new device identification matches the saved device identification of the hardware device, and the new startup count does not match the saved startup count of the hardware device, the temporary shielding operation on the hardware device is released, and the second connection prompt information is redisplayed.
[0083] In this step, if the new device identifier matches the device identifier of the saved hardware device, it means that the re-determined hardware device is a temporarily blocked device. Further, it can be determined whether the new startup count matches the startup count of the hardware device corresponding to the saved device identifier. If the new startup count does not match the startup count of the saved hardware device, it means that the hardware device has been restarted. After the user restarts the hardware device, the user's demand for whether to connect to the hardware device in the first connection mode may change. Therefore, the temporary blocking operation can be directly lifted and the second connection prompt information can be redisplayed.
[0084] Among them, the new device identifier matches the device identifier of the saved hardware device, which can be the same as the device identifier of the saved hardware device. The new startup count does not match the saved startup count of the hardware device, which can be different from the saved startup count of the hardware device. For example, assuming that the saved startup count is 10 and the new startup count is 11, it can be confirmed that the new startup count does not match the saved startup count of the hardware device. The redisplay of the second connection prompt information can be the same as the content of the first connection prompt information displayed previously.
[0085] In an embodiment of the present invention, by re-receiving a new device identification and a new number of startups, the new device identification matches the device identification of the saved hardware device, and the new number of startups does not match the saved number of startups of the hardware device, that is, after the hardware device is restarted, the temporary shielding operation of the hardware device is directly lifted, so that the hardware device can be temporarily shielded during the life cycle of the hardware device from device startup to device shutdown. At the same time, there is no need for the user to manually lift the temporary shielding of the hardware device. For example, the shielding can be lifted without manually removing the hardware device from the blacklist, thereby simplifying the user operation to a certain extent. Furthermore, after the temporary shielding operation of the hardware device is lifted, the second connection prompt information is redisplayed, which can ensure that the user is not disturbed by the displayed connection prompt information during the temporary shielding period of the hardware device, and can also facilitate the user to easily re-establish a connection with the hardware device, thereby improving the connection efficiency to a certain extent.
[0086] In another embodiment, when the new device identification matches the saved device identification of the hardware device, and the new startup count matches the saved startup count of the hardware device, the temporary shielding of the hardware device is maintained. This achieves the effect of temporarily shielding the hardware device within a life cycle, avoiding repeated pop-up connection reminders and bringing a bad user experience.
[0087] Optionally, in an implementation of the embodiment of the present invention, the operation of connecting to the hardware device according to the pre-stored valid information of the hardware device may be implemented by the following sub-steps:
[0088] Sub-step (1): connecting to the hardware device based on preset authentication conditions and the valid information; wherein the preset authentication conditions include: when the hardware device communicates with the third-party device in a second connection mode, the device identification of the third-party device obtained through the second connection mode.
[0089] In this step, the device identifier can be used to uniquely characterize the third-party device, and the specific content of the device identifier can be selected according to actual needs, and the embodiment of the present invention does not limit this. For example, the universally unique identifier (UUID) of the client corresponding to the hardware device installed in the third-party device can be used as the device identifier of the third-party device. Among them, the UUIDs of the clients installed in different third-party devices are different. Further, when the hardware device and the third-party device are connected in communication in the second connection mode, the device identifier can be directly sent to the hardware device based on the communication channel between the two, and the hardware device can store the received device identifier for authentication during subsequent connections. For example, the hardware device can confirm that the third-party device has the connection authority when the device identifier carried in the connection request sent by the third-party device matches the device identifier obtained by the hardware device. Further, in the case of having the connection authority, a connection can be further established with the third-party device based on valid information.
[0090] In an embodiment of the present invention, when a hardware device is communicated with a third-party device in a second connection mode, the device identification of the third-party device obtained through the second connection mode is used as a preset authentication condition, so that when a connection is established with the hardware device in a first connection mode, there is no need to manually perform an authentication operation, and authentication can be achieved directly based on the device identification, thereby simplifying user operations to a certain extent and further improving connection efficiency.
[0091] Optionally, the valid information in the embodiment of the present invention may include a connection identifier and a connection password of the hardware device in the first connection mode. Accordingly, in one implementation, before connecting to the hardware device according to the pre-stored valid information of the hardware device, it may include: determining to connect the hardware device based on the connection identifier. In this step, the connection identifier may be an identifier used to uniquely characterize the hardware device in the first connection mode. For example, the connection identifier may be the device name of the hardware device. Available devices around may be searched, and then the device whose name matches the connection identifier may be automatically connected. It should be noted that the device name may include a type field of the hardware type to which the hardware device belongs. The type fields of different hardware types are different. For example, the type field of a drone may be "DGI" and the type field of a handheld gimbal may be "pocket". Accordingly, when searching for available devices, the device whose name contains the type field of the hardware type to which the hardware device belongs may be used as an available device. For example, when the hardware device is a drone, the device whose name contains "DGI" may be used as an available device. In this way, the number of available devices may be reduced to a certain extent, thereby improving the efficiency of determining the hardware device from the available devices.
[0092] In the embodiment of the present invention, the hardware device can be directly determined by the connection identifier in the pre-stored valid information. In this way, the connection can be achieved without waiting for the user to manually select the hardware device to be connected, thereby shortening the time required for connection to a certain extent and further improving the connection efficiency.
[0093] Further, connecting with the hardware device according to pre-stored valid information of the hardware device may include:
[0094] Sub-step 10: Sending a connection request carrying the connection password and the device identification of the third-party device to the hardware device to connect to the hardware device.
[0095] In this step, the connection password and device identification can be used to determine whether the third-party device has connection permission. For example, if the carried connection password matches the preset connection password of the hardware device, and the carried device identification matches the device identification pre-stored in the hardware device, the hardware device can agree to establish a connection with the third-party device, thereby achieving connection with the hardware device.
[0096] In the embodiment of the present invention, a connection request carrying the connection password and the device identification of the third-party device is directly sent to the hardware device based on the connection password in the valid information to achieve connection with the hardware device. In this way, the connection can be achieved without waiting for the user to manually enter the connection password, thereby shortening the time required for connection to a certain extent and further improving the connection efficiency.
[0097] Optionally, in an implementation of the embodiment of the present invention, the operation of connecting to the hardware device according to the pre-stored valid information of the hardware device may also be implemented by the following sub-steps:
[0098] Sub-step 21: When the third-party device enters the preset mode, detect connectable devices around the third-party device; the connectable devices are devices that can be connected to the third-party device in the first connection mode.
[0099] The preset mode corresponds to a high-speed download mode of direct connection.
[0100] In this step, the preset mode may be a mode for determining the hardware device from the surrounding connectable devices and connecting. In actual application scenarios, hardware devices often send broadcast signals, and third-party devices can sense the existence of the hardware device by sending broadcast information. If a third-party device can receive the broadcast signal of a device, it means that the device is within the connectable range of the third-party device and can be connected by the third-party device in the first connection mode. Further, the connectable devices around the third-party device are devices within the connectable range of the third-party device. When detecting the connectable devices around the third-party device, it may be to receive the surrounding broadcast signals and use the devices corresponding to the broadcast signals that can be received as connectable devices. It should be noted that in the embodiment of the present invention, it is also possible to detect whether the device name of any searched device contains the preset type field corresponding to the hardware device; then, the device whose device name contains the preset type field corresponding to the hardware device is determined as the connectable device. Among them, the preset type field corresponding to the hardware device may be the type field of the hardware type to which the hardware device belongs. For example, in the case where the hardware device is a drone, the preset type field corresponding to the hardware device may be the type field characterizing the drone: "DGI". In this way, by selecting a device whose device name contains a preset type field corresponding to the hardware device as a connectable device, the number of connectable devices can be reduced to a certain extent, thereby improving the efficiency of determining the hardware device from the connectable devices.
[0101] Sub-step 22: determining the hardware device from the connectable devices according to the signal parameters of the broadcast signal sent by each of the connectable devices.
[0102] In this step, the signal parameter may be a parameter that can measure the distance between the connectable device and the third-party device. For example, the signal parameter may be signal strength, such as received signal strength indication (RSSI). The farther the connectable device is from the third-party device, the smaller the signal strength of the broadcast signal received by the third-party device tends to be. The closer the connectable device is to the third-party device, the greater the signal strength of the broadcast signal received by the third-party device tends to be. Therefore, the signal strength may be used as a signal parameter to determine the hardware device to be connected from the connectable devices. It should be noted that in an embodiment of the present invention, the operation of detecting the connectable devices around the third-party device and determining the hardware device from the connectable devices may be performed periodically so that the hardware device can be discovered in a timely manner.
[0103] Sub-step 203: Connecting to the hardware device according to pre-stored valid information of the hardware device.
[0104] In this step, the valid information may include a connection password. Specifically, a connection request carrying the connection password and a device identification of the third-party device may be sent to the hardware device to connect to the hardware device.
[0105] In the embodiment of the present invention, by detecting the surrounding connectable devices, the hardware device can be automatically determined according to the signal parameters of the broadcast signal sent by the connectable device, and the hardware device can be connected according to the pre-stored valid information of the hardware device. In this way, since the user does not need to manually select the hardware device from the surrounding connectable devices, the user operation can be simplified to a certain extent and the connection efficiency can be improved.
[0106] Optionally, in an implementation manner of the embodiment of the present invention, the above-mentioned determining the operation of the hardware device from the connectable devices according to the signal parameters of the broadcast signal sent by each of the connectable devices can be implemented by the following sub-steps:
[0107] Sub-step 221: determining a connectable device with the greatest signal strength according to the signal strength of the broadcast signal sent by each of the connectable devices; and determining the connectable device with the greatest signal strength as the hardware device.
[0108] In this step, the third-party device can detect the signal strength of the broadcast signals sent by each connectable device, and then determine the connectable device with the highest signal strength by comparing the strengths of each signal. Since the distances between different connectable devices and the third-party device may be different, the signal strengths of the broadcast signals received by the third-party device are often different. If the signal strength is greater, it means that the connectable device is closer to the third-party device. In actual application scenarios, the user's own hardware device is often closest to the user. Therefore, in this step, the connectable device with the highest signal strength can be directly determined as the hardware device. For example, Figure 5 is a detection schematic diagram provided by an embodiment of the present invention, such as Figure 5 As shown, there are 4 connectable devices around, among which the connectable device with an RSSI value of -30 has the largest signal strength. Therefore, the connectable device can be determined as the hardware device that needs to be connected.
[0109] Further, in order to avoid performing unnecessary operations, in an embodiment of the present invention, it is also possible to first detect whether there is a connectable device with a signal strength greater than a preset strength threshold. If there is a connectable device with a signal strength not less than the preset strength threshold, the operation of determining the hardware device from the connectable device is performed. Among them, the preset strength threshold can be a minimum strength value set according to actual needs. If the signal strength of a connectable device is less than the preset strength threshold, it can be considered that the distance between the connectable device and the third-party device is far, and it is highly likely that the connectable device does not belong to the hardware device that the third-party device needs to connect. Specifically, the signal strength corresponding to each connectable device can be compared with the preset strength threshold first. If the signal strength corresponding to the connectable device is less than the preset strength threshold, it can be considered that the surrounding connectable devices do not belong to the device that the user intends to connect. If there is a connectable device with a corresponding signal strength not less than the preset strength threshold, the operation of determining the hardware device from the connectable device is performed. In this way, it is possible to avoid performing unnecessary operations of determining the hardware device from the connectable device, and avoid establishing a connection with a hardware device that the user does not need to connect. At the same time, without performing the operation of determining the hardware device from the connectable device, it is possible to avoid displaying the first connection prompt information to the user, thereby avoiding unnecessary interference to the user.
[0110] In the embodiment of the present invention, there is no need for the user to manually select the hardware device to be connected from the surrounding connectable devices. By directly determining the connectable device with the largest signal strength as the hardware device, the user operation can be simplified and the connection efficiency can be improved. At the same time, the accuracy of the determined hardware device can be ensured to a certain extent, thereby reducing the probability of connecting to the wrong device.
[0111] Figure 6 is a flowchart of another device connection method provided by an embodiment of the present invention. The method can be applied to hardware devices such as Figure 6 As shown, the method may include:
[0112] Step 201: When the hardware device communicates with the third-party device for the first time in a first connection mode, the hardware device connects with the third-party device according to the pre-stored authentication information of the third-party device; wherein the authentication information is obtained in the following manner: when the hardware device communicates with the third-party device in a second connection mode, the authentication information of the third-party device is obtained through the second connection mode. Before connecting with the third-party device according to the pre-stored authentication information of the third-party device, the third-party device enters a preset high-speed download mode according to a specific instruction.
[0113] For example, the user presses a physical button of the hardware device to input the specific instruction, so that the hardware device enters the high-speed download mode.
[0114] The hardware device and the third-party device in the embodiment of the present invention may be the hardware device and the third-party device involved in the aforementioned embodiment. When the hardware device and the third-party device are communicatively connected in the second connection mode, since the two have already been communicatively connected, the authentication information can be conveniently obtained and pre-stored in the hardware device directly through the communication connection established in the second connection mode in this way for subsequent use. Accordingly, when the hardware device and the third-party device are communicatively connected in the first connection mode for the first time, the pre-stored authentication information can be directly read from the inside, and the communication connection in the first connection mode can be established based on the authentication information. It should be noted that when the hardware device and the third-party device are not communicatively connected in the first connection mode for the first time, they can also be directly connected to the hardware device based on the pre-stored authentication information, and the embodiment of the present invention does not limit this.
[0115] In summary, the device connection method provided by the embodiment of the present invention obtains the authentication information of the third-party device through the second connection mode when the hardware device communicates with the third-party device in the second connection mode. When the hardware device communicates with the third-party device in the first connection mode for the first time, since the authentication information of the third-party device is obtained and pre-stored in advance, when the communication is connected in the first connection mode, the hardware device can directly perform the authentication operation on the third-party device based on the internal pre-stored authentication information, thereby improving the connection efficiency of establishing a connection with the hardware device to a certain extent.
[0116] Optionally, in an implementation of the embodiment of the present invention, the authentication information may include a device identifier of the third-party device. Accordingly, the operation of connecting to the third-party device according to the pre-stored authentication information of the third-party device may include the following sub-steps:
[0117] Step 2011: Receive a connection request sent by the third-party device; the connection request carries a device identifier and a connection password.
[0118] In this step, the connection request may be the connection request sent by the third-party device in the above-mentioned embodiment. By carrying the device identification and connection password in the sent connection request, it is convenient for the hardware device to determine whether a connection can be established with the third-party device.
[0119] Step 2012: If the device identifier carried in the connection request matches the device identifier in the authentication information, and the connection password matches the preset connection password, then connect to the third-party device.
[0120] In this step, pre-storing the device identification can be equivalent to adding the device identification to the whitelist, and the third-party device indicated by the device identification in the whitelist has the connection permission. Furthermore, if the carried connection password matches the device identification in the authentication information stored by the hardware device, it can be confirmed that the third-party device has passed the authentication operation. Further, it can be determined whether the carried connection password is the same as the preset connection password. If the connection password is the same as the preset connection password, it can be confirmed that the third-party device is the hardware device user's own device. Accordingly, the hardware device can agree to establish a connection with the third-party device, thereby achieving connection with the third-party device.
[0121] In an existing implementation, the user is often required to perform a connection confirmation operation on the hardware device, such as clicking a specific button, to achieve authentication. In the embodiment of the present invention, based on the device identification in the pre-stored authentication information, authentication can be conveniently achieved without manual operation, thereby further simplifying user operations and improving connection efficiency.
[0122] In one application scenario, in order to ensure the download speed of the collected content from the hardware device, it is necessary to determine the user's own hardware device from the surrounding connectable devices, and based on the first connection method, the hardware device is directly connected to the third-party device, so that the third-party device can download at high speed. In an existing implementation method, it is necessary to first display the surrounding connectable devices to the user, and the user selects the hardware device to be connected from them, which leads to low connection efficiency. To this end, another device connection method is proposed in an embodiment of the present invention.
[0123] Specifically, take the hardware device as a drone, and the collected content as an original image collected by a camera mounted on the drone as an example. Figure 7 is a flowchart of another device connection method provided by an embodiment of the present invention. The method can be applied to the communication connection between a third-party device and a target drone. The drone can be equipped with a camera, and the camera can be used to collect original images, such as Figure 7 As shown, the method may include:
[0124] Step 301: When the third-party device enters a preset mode, a connectable device around the third-party device is detected; the connectable device is a drone device that can be connected to the hardware device in a first connection mode; the first connection mode is used to enable the third-party device and the drone to be directly connected, and enable the third-party device to obtain the original image at high speed.
[0125] The preset mode refers to the high-speed download mode.
[0126] The third-party device in the embodiment of the present invention may be the third-party device involved in the aforementioned embodiment. The preset mode may be set according to actual needs. If the third-party device enters the preset mode, it may be considered that the user's own hardware device needs to be determined from the surroundings at present, and a connection is established with the hardware device based on the first connection method. Furthermore, when detecting connectable devices around the third-party device, the surrounding available devices may be searched first, and the device whose name contains the type field of the hardware type to which the drone belongs may be used as a connectable device. For example, a device whose name contains "DGI" may be used as a connectable device. In this way, the number of connectable devices may be reduced to a certain extent, thereby improving the efficiency of determining the target drone from the connectable devices.
[0127] Furthermore, since the first connection mode allows the third-party device and the drone to be directly connected, the transmission speed of the connection channel established based on the first connection mode is often relatively high. Accordingly, after establishing a connection with the target drone based on the first connection mode, the third-party device can obtain the original image captured by the target drone at a high speed. Among them, the high-speed acquisition in the embodiment of the present invention refers to acquisition at a speed supported by the first connection mode.
[0128] Step 302: Determine the target drone from the connectable devices according to the signal parameters of the broadcast signals sent by each of the connectable devices.
[0129] Specifically, in this step, the implementation method of the target drone is determined from the connectable devices according to the signal parameters of the broadcast signals sent by each connectable device. The implementation method of the hardware device is determined from the connectable devices according to the signal parameters of the broadcast signals sent by each connectable device in the aforementioned embodiment, which will not be repeated here.
[0130] For example, when the signal strength of the Bluetooth signal of each of the connectable devices is determined, the device with the largest Bluetooth signal strength among the connectable devices is determined to be the target drone. The connectable device first communicates with the target drone based on the Bluetooth signal, obtains the WIFI SSID and password of the target drone through the Bluetooth signal, and then establishes a direct connection based on the WIFI signal with the target drone based on the WIFI SSID and password of the target drone. The direct connection based on the WIFI signal enables the third-party device to download the original image on the target drone at a high speed.
[0131] Step 303: communicate with the target UAV according to the first connection mode.
[0132] In summary, the device connection method provided by the embodiment of the present invention can automatically determine the target drone according to the signal parameters of the broadcast signal sent by the connectable device by detecting the surrounding connectable devices, and communicate with the target drone according to the first connection mode. In this way, since the user does not need to manually select the target drone from the surrounding connectable devices, the user operation can be simplified to a certain extent and the connection efficiency can be improved.
[0133] Optionally, in an implementation of the embodiment of the present invention, after establishing a communication connection with the target drone according to the first connection mode, the following steps may be performed:
[0134] Step F: Downloading the original image captured by the target UAV based on the communication connection of the first connection mode.
[0135] For example, the third-party device may send an acquisition instruction to the target drone, and after receiving the acquisition instruction, the target drone may send the collected original image to the third-party device through the communication connection established in the first connection mode.
[0136] In an embodiment of the present invention, based on the communication connection established under the first connection mode that enables a third-party device and a target drone to be directly connected, the original image collected by the target drone is downloaded, so that the original image can be acquired at a high speed, thereby ensuring the image download speed to a certain extent and improving the download efficiency.
[0137] Optionally, in an implementation of the embodiment of the present invention, the third-party device can enter the preset mode in the following manner: when the communication connection established between the third-party device and the drone in the second connection mode is converted from a first preset state to a second preset state, the preset mode is entered; when a switching instruction from the user is received, the preset mode is entered; or, when a connection instruction to directly enter the first connection mode is received, the preset mode is entered.
[0138] Among them, the first connection mode may include one or more of Bluetooth connection and Wi-Fi network connection, and the second connection mode may include the third-party device being connected to the target drone through a remote control device. By connecting the remote control device to the target drone as the second connection mode, the target drone can be controlled to perform various tasks more conveniently. Among them, the remote control device may be a remote controller paired with the target drone, the remote control device may be connected to the target drone through an SDR, and the target drone may be controlled by the remote control device. The first preset state may include the remote control device being normally connected to the target drone and the remote control device being normally connected to the third-party device, and the second preset state may include the remote control device being disconnected from the target drone, the connection being unstable, or an abnormality occurring; the second preset state also includes the remote control device being disconnected from the third-party device, the connection being unstable, or an abnormality occurring.
[0139] In actual application scenarios, if the remote control device is connected to the target drone normally, it can be said to a certain extent that the user is currently in a state where he needs to use the remote control device to control the target drone. Furthermore, if the communication connection of the second connection method is converted from the first preset state to the second preset state. In this case, the third-party device determines to enter the preset mode, and often needs to establish a connection in other connection methods. Accordingly, when the communication connection of the second connection method is converted from the first preset state to the second preset state, it can be considered that the user is more likely to need to establish a connection in the first connection method in the current usage scenario. Therefore, the preset mode can be entered to connect the third-party device to the target drone through the first connection method, which is convenient for subsequent users to use.
[0140] Furthermore, the switching instruction may be sent by the user when the user needs to switch the second connection mode to the first connection mode, and the connection instruction to directly enter the first connection mode may be sent by the user when the user needs to directly enter the first connection mode. Accordingly, after the third-party device receives the switching instruction, it can determine that the user currently needs to use the first connection mode to connect to the target drone, and therefore, it can enter the preset mode. Furthermore, after the third-party device receives the switching instruction, it can determine that the user currently needs to directly use the first connection mode to connect to the target drone, and therefore, it can directly enter the preset mode.
[0141] In the embodiment of the present invention, by actively entering the preset mode when the communication connection in the second connection mode is converted from the first preset state to the second preset state, the preset mode can be conveniently entered without waiting for user operation, thereby improving the efficiency of entering the preset mode to a certain extent. Entering the preset mode when receiving a switching instruction or a connection instruction sent by the user can improve the flexibility of user control, avoid performing unnecessary operations to enter the preset mode, and save operating resources to a certain extent.
[0142] Optionally, in an implementation of the embodiment of the present invention, before establishing a communication connection with the target drone according to the first connection mode, the following steps may be further performed:
[0143] Step G: displaying a third connection prompt message; the third connection prompt message is used to indicate whether to establish a communication connection with the target UAV through the first connection mode;
[0144] Step H: if a third operation for the third connection prompt information is received, the operation of communicating and connecting with the target drone according to the first connection mode is performed;
[0145] Step I: If a fourth operation is received for the third connection prompt information, a temporary shielding operation is performed on the target drone based on the current startup times and device identification of the target drone.
[0146] Specifically, the implementation of the above steps G to I can refer to the relevant descriptions in the above steps A to C, which will not be repeated here.
[0147] In the embodiment of the present invention, by first displaying the third connection prompt information before connecting with the target drone, the user performs the third operation on the third connection prompt information, that is, the user ensures that the target drone is to be connected, and then performs the operation of communicating and connecting with the target drone according to the first connection method, thereby avoiding the probability of connecting to the wrong device to a greater extent and improving the connection effect. At the same time, when the user does not need to connect to the target drone at present, the user can perform the fourth operation on the third connection prompt information to implement the temporary shielding operation on the target drone, thereby improving the operational efficiency of temporarily shielding the hardware device to a certain extent.
[0148] Optionally, in an implementation of the embodiment of the present invention, the broadcast signal of the target drone may carry a device identifier and a startup count. Accordingly, the step of performing a temporary shielding operation on the target drone based on the current startup count and device identifier of the target drone may include:
[0149] Step I1: Obtain the current startup times and device identification of the target UAV from the broadcast signal of the target UAV;
[0150] Step I2: Save the current startup times and device identification of the target UAV.
[0151] Specifically, the implementation of the above steps I1 to I2 can refer to the relevant descriptions in the above steps C1 to C2:, which will not be repeated here.
[0152] In an embodiment of the present invention, by obtaining the current startup times and device identification of the target UAV from the broadcast signal and saving the current startup times and device identification, the target UAV can be conveniently temporarily shielded, thereby improving the shielding efficiency to a certain extent.
[0153] Furthermore, the embodiment of the present invention may also perform the following steps after performing a temporary shielding operation on the target drone:
[0154] Step J, after performing a temporary shielding operation on the target UAV, a new device identification and a new start-up number are received again;
[0155] Step K: When the new device identification matches the device identification of the target UAV, and the new startup count does not match the saved startup count of the target UAV, the temporary shielding operation on the target UAV is released, and the fourth connection prompt information is redisplayed.
[0156] Specifically, the implementation of the above steps J to K can refer to the relevant descriptions in the above steps D to E, which will not be repeated here.
[0157] In the embodiment of the present invention, by re-receiving a new device identification and a new number of startups, the new device identification matches the device identification of the saved target drone, and the new number of startups does not match the number of startups of the saved target drone, that is, after the target drone is restarted, the temporary shielding operation of the target drone is directly released, so that the target drone can be temporarily shielded during a life cycle from device startup to device shutdown. At the same time, there is no need for the user to manually release the temporary shielding of the target drone, for example, the target drone can be released without manually removing the target drone from the blacklist, thereby simplifying the user operation to a certain extent. Furthermore, after the temporary shielding operation of the target drone is released, the fourth connection prompt information is redisplayed, which can ensure that the user is not disturbed by the displayed connection prompt information during the temporary shielding period of the target drone, and it can also facilitate the user to easily re-establish a connection with the target drone, thereby improving the connection efficiency to a certain extent.
[0158] Optionally, in an implementation manner of the embodiment of the present invention, the step of determining the target drone from the connectable devices according to the signal parameters of the broadcast signals sent by each of the connectable devices may include:
[0159] Step 3021 determines the connectable device with the greatest signal strength according to the signal strength of the broadcast signal sent by each of the connectable devices; and determines the connectable device with the greatest signal strength as the target drone.
[0160] Specifically, the specific implementation method of the above step 3021 can refer to the relevant description in the above sub-step 221, which will not be repeated here.
[0161] In the embodiment of the present invention, there is no need for the user to manually select the target drone to be connected from the surrounding connectable devices. By directly determining the connectable device with the largest signal strength as the target drone, the user operation can be simplified, the connection efficiency can be improved, and the accuracy of the determined target drone can be ensured to a certain extent, thereby reducing the probability of connecting to the wrong device.
[0162] Optionally, in an implementation of the embodiment of the present invention, before determining the target drone from the connectable devices according to the signal parameters of the broadcast signals sent by each of the connectable devices, the following steps may also be performed:
[0163] Step L: Detect whether there is a connectable device having a signal strength greater than a preset strength threshold according to the signal parameters of the broadcast signal sent by each of the connectable devices.
[0164] Step M: If there is a connectable device whose signal strength is greater than a preset strength threshold, the operation of determining the target drone from the connectable devices is performed.
[0165] Specifically, the specific implementation of the above steps L to M can refer to the above related descriptions, which will not be repeated here.
[0166] In the embodiment of the present invention, the operation of determining the target drone from the connectable device is performed only when there is a connectable device with a signal strength greater than a preset strength threshold. In this way, it is possible to avoid performing unnecessary operations of determining hard target drones from connectable devices and avoid establishing connections with target drones that the user does not need to connect to. At the same time, when the operation of determining the target drone from the connectable device is not performed, it is possible to avoid displaying the third connection prompt information to the user, thereby avoiding unnecessary interference to the user.
[0167] Optionally, in an implementation of the embodiment of the present invention, the following steps may also be performed:
[0168] Step N: When the communication connection established between the third-party device and the target drone in the second connection mode is in a first preset state, sending authentication information to the target drone; the authentication information includes a device identification of the third-party device.
[0169] Since the communication connection established between the third-party device and the target drone in the second connection mode is in the first preset state, the third-party device and the target drone can transmit information normally. Therefore, the authentication information can be sent directly to the target drone. In this way, there is no need to establish a special connection for sending the authentication information, and the established connection can be directly used for sending, which can reduce the cost of sending the authentication information and improve the sending efficiency. Accordingly, the target drone can receive and store the authentication information accordingly.
[0170] Further, when the authentication information is sent to the target drone, a connection request carrying a device identifier can be sent to the target drone to implement the operation of communicating and connecting with the target drone according to the first connection mode. In specific implementation, the target drone can authenticate the third-party device based on the device identifier carried in the connection request. For example, the target drone can confirm that the third-party device has passed the authentication when the device identifier carried matches the device identifier included in the received authentication information. In this way, the authentication operation of the third-party device can be automatically implemented without manual operation by the user, thereby simplifying the user operation to a certain extent and improving the connection efficiency. Optionally, in an implementation of an embodiment of the present invention, the connection information of the second connection mode of the target drone can also be obtained when the communication connection established between the third-party device and the target drone in the second connection mode is in the first preset state; the connection information includes the connection password under the first connection mode. For example, the third-party device can send a password acquisition request based on the communication connection established in the second connection mode, and accordingly, the target drone can return the connection password after receiving the password acquisition request. Accordingly, when the connection request carrying the device identifier is sent to the target drone, it can be a connection request carrying the device identifier and the connection password. For example, when the carried connection password matches the preset connection password of the target drone, and the carried device identifier matches the device identifier in the authentication information pre-stored in the target drone, the target drone device may agree to establish a connection with the third-party device, thereby achieving connection with the target drone. In an embodiment of the present invention, a connection password is obtained through a communication connection under an established second connection mode. When a connection request is subsequently sent, there is no need to obtain an additional password. The pre-obtained connection password can be directly carried to quickly establish a connection with the target drone, thereby improving the connection efficiency to a certain extent. Optionally, in an implementation method of an embodiment of the present invention, the connection information may also include a connection identifier of the target drone. After obtaining the connection information of the second connection mode of the target drone, the following steps may also be performed:
[0171] Step O: When the switching condition is met, disconnect the communication connection established in the second connection mode.
[0172] In this step, the switching condition can be set according to actual needs. For example, the switching condition can be that the second connection mode enters the second preset state, or a switching instruction is received, etc. Further, when the switching condition is met, the communication connection currently established in the second connection mode can be disconnected first, so as to facilitate subsequent switching to other connection modes. For example, Figure 8 is another interface schematic diagram provided by an embodiment of the present invention, such as Figure 8 As shown, the user can click button 02 in the album interface. Accordingly, the third-party device can display to the user after detecting that the user has clicked button 02. Fig. 9 The switching option 03 is shown. Further, the user can click on the Fig. 9 The switching option 03 shown in FIG. 1 , accordingly, after detecting that the user clicks the switching option 03, the third-party device can confirm that the current switching condition is met, and then can perform subsequent switching operations. It should be noted that Fig. 9 The text content displayed in the figure is only a schematic description. In actual application, the specific content can be set according to actual needs. For example, the text content displayed can also be set to "GOFLY it will switch to HD transmission, and the connection will be cut off for a short time. Please wait patiently". Furthermore, after the subsequent switching operation is completed, the user can return to Figure 8 The interface shown is based on Figure 8 The interface shown continues to browse the album. Since the target drone is connected to the third-party device in the first connection mode after the switch, the third-party device can quickly obtain the pictures in the target drone and display them in the album during the browsing of the album, thereby avoiding the problem of browsing freezes due to untimely loading to a certain extent. It should be noted that after the user clicks on the switch option, the third-party device can also display information about the current connection status to the user. For example, Fig.10 is another interface schematic diagram provided by an embodiment of the present invention, such as Fig.10 As shown, the interface displays the connection status "Connecting". Fig.11 is another interface schematic diagram provided by an embodiment of the present invention, such as Fig.11 As shown, the interface displays the connection status "Connection successful".
[0173] Step P: determining the target drone based on the connection identifier, and establishing a communication connection with the target drone in a first connection mode based on the connection password.
[0174] In this step, the available devices around can be searched, and then the device whose name matches the connection identifier can be determined as the target drone. Furthermore, a connection request carrying a connection password can be sent to the target drone to establish a communication connection with the target drone in the first connection mode. In the embodiment of the present invention, by pre-acquiring the connection identifier and the connection password, when switching the connection mode, there is no need to display the re-scanned available devices around to the user, and the user does not need to perform the operation of selecting the target drone from them. The switch to the first connection mode can be achieved directly according to the pre-acquired connection identifier and connection password, thereby simplifying the user operation to a certain extent and improving the switching efficiency.
[0175] Fig.12 It is a block diagram of a device connection device provided by an embodiment of the present invention, which can be applied to a third-party device, and the device may include: a memory 401 and a processor 402. The memory 401 is used to store program code. The processor 402 calls the program code, and when the program code is executed, it is used to perform the following operations: when the third-party device communicates and connects with the hardware device for the first time in a first connection mode, it connects with the hardware device according to the pre-stored valid information of the hardware device; wherein the valid information is obtained in the following manner: when the third-party device communicates and connects with the hardware device in a second connection mode, it obtains the valid information of the hardware device through the second connection mode; wherein the valid information is associated with the first connection mode. Specifically, the specific operations performed by the processor 402, the specific implementation process of each operation, and the technical effects that can be achieved can refer to the relevant description in the aforementioned method embodiment, and will not be repeated here.
[0176] Fig.13 It is a block diagram of another device connection device provided by an embodiment of the present invention, which can be applied to hardware devices, and the device may include a memory 501 and a processor 502. The memory 501 is used to store program code. The processor 502 calls the program code, and when the program code is executed, it is used to perform the following operations: when the hardware device communicates with the third-party device for the first time in a first connection mode, it connects with the third-party device according to the pre-stored authentication information of the third-party device; wherein the authentication information is obtained in the following manner: when the hardware device communicates with the third-party device in a second connection mode, the authentication information of the third-party device is obtained through the second connection mode. Specifically, the specific operations performed by the processor 502, the specific implementation process of each operation, and the technical effects that can be achieved can refer to the relevant description in the aforementioned method embodiment, and will not be repeated here.
[0177] Fig.14It is a block diagram of another device connection device provided by an embodiment of the present invention. The device can be applied to the communication connection between a third-party device and a target drone. The drone is equipped with a camera, and the camera is used to collect original images. The device may include: a memory 601 and a processor 602. The memory 601 is used to store program code. The processor 602 calls the program code. When the program code is executed, it is used to perform the following operations: when the third-party device enters the preset mode, detect the connectable devices around the third-party device; the connectable device is a drone device that can be connected to the hardware device in a first connection mode; the first connection mode is used to enable the third-party device and the drone to be directly connected, and enable the third-party device to obtain the original image at high speed; according to the signal parameters of the broadcast signal sent by each of the connectable devices, determine the target drone from the connectable devices; and communicate with the target drone according to the first connection mode. Specifically, the specific operations performed by the processor 602 and the specific implementation process of each operation and the technical effects that can be achieved can refer to the relevant description in the aforementioned method embodiment, which will not be repeated here. Further, the embodiment of the present invention also provides a hardware device, which is used to perform the steps in the aforementioned method embodiment applied to the hardware device. Optionally, the hardware device is a drone and / or an unmanned vehicle. Furthermore, an embodiment of the present invention also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, each step in the above-mentioned device connection method is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0178] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. A person of ordinary skill in the art can understand and implement it without creative labor. The various component embodiments of the present invention may be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. A person of ordinary skill in the art should understand that a microprocessor or a digital signal processor may be used in practice to implement some or all of the functions of some or all of the components in the computing processing device according to an embodiment of the present invention. The present invention may also be implemented as a device or apparatus program (e.g., a computer program and a computer program product) for executing part or all of the methods described herein. Such a program for implementing the present invention may be stored on a computer-readable medium, or may be in the form of one or more signals. Such a signal may be downloaded from an Internet website, or provided on a carrier signal, or provided in any other form. For example, Fig.15 A block diagram of a computing and processing device provided by an embodiment of the present invention, such as Fig.15 As shown, Fig.15 A computing processing device that can implement the method according to the present invention is shown. The computing processing device traditionally includes a processor 710 and a computer program product or a computer-readable medium in the form of a memory 720. The memory 720 can be an electronic memory such as a flash memory, an EEPROM (electrically erasable programmable read-only memory), an EPROM, a hard disk or a ROM. The memory 720 has a storage space 730 for program codes for executing any method steps in the above method. For example, the storage space 730 for program codes may include individual program codes for implementing various steps in the above method respectively. These program codes can be read from or written to one or more computer program products. These computer program products include program code carriers such as a hard disk, a compact disk (CD), a memory card or a floppy disk. Such a computer program product is usually as shown in reference Fig.16 The portable or fixed storage unit. The storage unit may have Fig.15 The memory 720 in the computing and processing device of the computer 720 is similarly arranged as a storage segment, a storage space, etc. The program code can be compressed, for example, in an appropriate form. Generally, the storage unit includes computer readable code, that is, code that can be read by a processor such as 710, which, when executed by the computing and processing device, causes the computing and processing device to perform the various steps in the method described above.
[0179] Each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same and similar parts between the embodiments can be referred to each other. "One embodiment", "embodiment" or "one or more embodiments" referred to herein means that the specific features, structures or characteristics described in conjunction with the embodiment are included in at least one embodiment of the present invention. In addition, please note that the word examples of "in one embodiment" here do not necessarily all refer to the same embodiment. In the description provided here, a large number of specific details are described. However, it can be understood that the embodiments of the present invention can be practiced without these specific details. In some examples, well-known methods, structures and techniques are not shown in detail so as not to obscure the understanding of this specification. In the claims, any reference symbols between brackets should not be constructed as limitations on the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "one" or "an" before an element does not exclude the presence of multiple such elements. The present invention can be implemented by means of hardware including several different elements and by means of a suitably programmed computer. In a unit claim that lists several devices, several of these devices can be embodied by the same hardware item. The use of the words first, second, and third, etc. does not indicate any order. These words may be interpreted as names. Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them. Although the present invention has been described in detail with reference to the aforementioned embodiments, a person of ordinary skill in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present invention.
Claims
1. A device connection method, characterized in that: The method is applied to a third-party device, and the method comprises: When the third-party device communicates with the hardware device for the first time in a first connection mode, the third-party device is connected to the hardware device according to the pre-stored valid information of the hardware device; the first connection mode includes one or more of a Bluetooth connection and a Wireless Fidelity Wi-Fi network connection; wherein the valid information is obtained by: When the third-party device is communicatively connected to the hardware device via a second connection method, valid information of the hardware device is obtained via the second connection method; wherein the valid information is associated with the first connection method; the second connection method includes the third-party device being connected to the hardware device via a remote control device, and the remote control device is used to control the hardware device to perform tasks.
2. The method according to claim 1, characterized in that The connecting with the hardware device according to the pre-stored valid information of the hardware device includes: Connecting to the hardware device based on preset authentication conditions and the valid information; wherein the preset authentication conditions include: when the hardware device is communicatively connected with the third-party device in a second connection mode, the device identification of the third-party device obtained through the second connection mode.
3. The method according to claim 1, characterized in that The third-party device enters the first connection mode by: When the communication connection of the second connection mode is converted from the first preset state to the second preset state, the second connection mode is switched to the first connection mode; or, When receiving a switching instruction from the user, switching from the second connection mode to the first connection mode; Alternatively, when a connection instruction to directly enter the first connection mode is received, a communication connection is performed in the first connection mode.
4. The method according to claim 3, characterized in that The first preset state includes: the remote control device is normally connected to the third-party device and the remote control device is normally connected to the hardware device; The second preset state includes: the remote control device is disconnected from the hardware device, the connection is unstable or an abnormality occurs, and also includes the remote control device is disconnected from the third-party device, the connection is unstable or an abnormality occurs.
5. The method according to claim 1, characterized in that Before connecting with the hardware device according to the pre-stored valid information of the hardware device, the method further includes: Displaying first connection prompt information; the first connection prompt information is used to indicate whether to connect to the hardware device in the first connection mode; If a first operation for the first connection prompt information is received, the operation of connecting with the hardware device according to the pre-stored valid information of the hardware device is performed; If a second operation is received for the first connection prompt information, a temporary shielding operation is performed on the hardware device.
6. The method according to claim 5, characterized in that The broadcast signal of the hardware device includes a device identification and a startup count; and the temporarily shielding operation on the hardware device includes: Obtaining the current startup times and device identification of the hardware device from the broadcast signal of the hardware device; The current number of startup times and device identification obtained are saved in a preset blacklist to achieve temporary shielding of the hardware device.
7. The method according to claim 6, characterized in that The method further comprises: After performing a temporary shielding operation on the hardware device, a new device identification and a new startup count are received again; When the new device identification matches the saved device identification of the hardware device, and the new startup count does not match the saved startup count of the hardware device, the temporary shielding operation on the hardware device is released, and the second connection prompt information is redisplayed.
8. The method according to claim 1, characterized in that The valid information includes a connection identifier and a connection password of the hardware device in the first connection mode; before connecting with the hardware device according to the pre-stored valid information of the hardware device, the method further includes: Determining the hardware device based on the connection identifier; The connecting with the hardware device according to the pre-stored valid information of the hardware device includes: sending a connection request carrying the connection password and the device identification of the third-party device to the hardware device to connect with the hardware device.
9. The method according to claim 1, characterized in that: The connecting with the hardware device according to the pre-stored valid information of the hardware device includes: When the third-party device enters the preset mode, detecting connectable devices around the third-party device; the connectable devices are devices that can be connected to the third-party device in the first connection mode; Determining the hardware device from the connectable devices according to signal parameters of the broadcast signals sent by each of the connectable devices; Connecting to the hardware device is performed according to pre-stored valid information of the hardware device.
10. The method according to claim 9, characterized in that The determining the hardware device from the connectable devices according to the signal parameters of the broadcast signals sent by each of the connectable devices comprises: According to the signal strength of the broadcast signal sent by each of the connectable devices, the connectable device with the greatest signal strength is determined; and the connectable device with the greatest signal strength is determined as the hardware device.
11. The method according to claim 10, characterized in that Before determining the hardware device from the connectable devices according to the signal parameters of the broadcast signals sent by each of the connectable devices, the method further includes: According to the signal parameters of the broadcast signals sent by each of the connectable devices, detecting whether there is a connectable device with a signal strength greater than a preset strength threshold; If there is a connectable device whose signal strength is not less than the preset strength threshold, the operation of determining the hardware device from the connectable devices is performed.
12. A device connection method, characterized in that: The method is applied to a hardware device, and the method comprises: When the hardware device communicates with the third-party device for the first time in a first connection mode, the hardware device is connected to the third-party device according to the pre-stored authentication information of the third-party device; the first connection mode includes one or more of a Bluetooth connection and a Wireless Fidelity Wi-Fi network connection; wherein the authentication information is obtained by: When the hardware device is in communication connection with the third-party device in a second connection mode, obtaining authentication information of the third-party device in the second connection mode; The second connection mode includes the third-party device being connected to the hardware device via a remote control device, and the remote control device is used to control the hardware device to perform a task.
13. The method according to claim 12, characterized in that The authentication information includes a device identification of the third-party device; The connecting with the third-party device according to the pre-stored authentication information of the third-party device includes: Receiving a connection request sent by the third-party device; the connection request carries a device identifier and a connection password; If the device identification carried in the connection request matches the device identification in the authentication information, and the connection password matches the preset connection password, then the connection is made to the third-party device.
14. A device connection device, characterized in that: The device is applied to a third-party device, and the device includes a memory and a processor; The memory is used to store program codes; The processor calls the program code, and when the program code is executed, is used to perform the following operations: When the third-party device communicates with the hardware device for the first time in a first connection mode, the third-party device is connected to the hardware device according to the pre-stored valid information of the hardware device; the first connection mode includes one or more of a Bluetooth connection and a Wireless Fidelity Wi-Fi network connection; wherein the valid information is obtained by: When the third-party device is communicatively connected to the hardware device via a second connection method, valid information of the hardware device is obtained via the second connection method; wherein the valid information is associated with the first connection method; the second connection method includes the third-party device being connected to the hardware device via a remote control device, and the remote control device is used to control the hardware device to perform tasks.
15. A device connection device, characterized in that: The device is applied to a hardware device, and the device includes a memory and a processor; The memory is used to store program codes; The processor calls the program code, and when the program code is executed, is used to perform the following operations: When the hardware device communicates with the third-party device for the first time in a first connection mode, the hardware device is connected to the third-party device according to the pre-stored authentication information of the third-party device; the first connection mode includes one or more of a Bluetooth connection and a Wireless Fidelity Wi-Fi network connection; wherein the authentication information is obtained by: When the hardware device is in communication connection with the third-party device in a second connection mode, obtaining authentication information of the third-party device in the second connection mode; The second connection mode includes the third-party device being connected to the hardware device via a remote control device, and the remote control device is used to control the hardware device to perform a task.
16. A hardware device for realizing device connection, characterized in that: Comprising the device connecting apparatus as claimed in claim 15.
17. The hardware device for realizing device connection according to claim 16, characterized in that: The hardware device for realizing device connection is a drone and / or an unmanned vehicle.
18. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method described in any one of claims 1 to 13 is implemented.
Citation Information
Patent Citations
Client end and WI-FI connection method
CN106912085A
Terminal calling control method, terminal and computer-readable storage medium
CN107911532A