Equipment connection method and device, electronic equipment and readable storage medium

By sending relay request information to the second electronic device and processing wireless device information in cross-device application relay scenarios, the cumbersome operation problems in the prior art are solved, and the seamless connection between the wireless electronic device and the second electronic device is achieved, and the efficiency of user experience and equipment collaborative work is improved.

CN119521450APending Publication Date: 2025-02-25VIVO MOBILE COMM CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411742942.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-29
Publication Date
2025-02-25

AI Technical Summary

Technical Problem

In the prior art, the operation steps for applying relay across devices are relatively cumbersome, and users need to manually disconnect and reconnect the wireless device.

Method used

By sending the relay request information to the second electronic device, carrying the device information of the first electronic device, and after receiving the relay response information, the device information of the second electronic device is sent to the wirelessly connected wireless electronic device to realize the seamless connection between the wireless electronic device and the second electronic device.

Benefits of technology

The seamless connection between wireless electronic devices and the second electronic devices is realized, which avoids the tedious operation of manually disconnecting and reconnecting of users, improves the convenience and smoothness of user experience, and the automated device connection process reduces user waiting time and improves the efficiency of the application relay process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119521450A_ABST
    Figure CN119521450A_ABST
Patent Text Reader

Abstract

The invention discloses an equipment connection method and device, electronic equipment and a readable storage medium, and belongs to the technical field of communication. The method comprises the steps that relay request information is sent to second electronic equipment, and the relay request information carries first equipment information of first electronic equipment; under the condition that relay response information of the second electronic equipment is received, equipment information of the second electronic equipment is sent to wireless electronic equipment wirelessly connected with the first electronic equipment, so that wireless connection is established between the wireless electronic equipment and the second electronic equipment; or under the condition that relay response information of the second electronic equipment is received, equipment information of the wireless electronic equipment wirelessly connected with the first electronic equipment is sent to the second electronic equipment, so that wireless connection is established between the wireless electronic equipment and the second electronic equipment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the field of communication technology, and specifically relates to a device connection method, apparatus, electronic device and readable storage medium. Background Art

[0002] In daily life, users often need to switch between different devices to use applications, such as switching from a mobile phone to a tablet. In this scenario, users hope to be able to seamlessly relay applications between different devices, including the application status and data, as well as the hardware devices related to the application functions.

[0003] The current application relay solution mainly transfers the application page status and data to the other end by calling the system relay capability to achieve seamless application flow. For example, when a user uses a music playback application on a mobile phone, after the application is relayed to a tablet, the music program will continue to play on the tablet and maintain the original playback progress. When a user listens to music on a mobile phone through a Bluetooth headset, the Bluetooth headset requires the user to manually disconnect from the mobile phone and reconnect to the tablet. Therefore, the current cross-device application relay operation steps are relatively cumbersome. Summary of the invention

[0004] The purpose of the embodiments of the present application is to provide a device connection method, apparatus, electronic device and readable storage medium, which can solve the problem that the current cross-device application relay operation steps in the prior art are relatively cumbersome.

[0005] In a first aspect, an embodiment of the present application provides a device connection method, which is applied to a first electronic device, and the method includes:

[0006] Sending a relay request message to a second electronic device, where the relay request message carries first device information of the first electronic device;

[0007] When receiving the relay response information from the second electronic device, sending the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device; or

[0008] When the relay response information of the second electronic device is received, the device information of the wireless electronic device wirelessly connected to the first electronic device is sent to the second electronic device so that the wireless electronic device can establish a wireless connection with the second electronic device.

[0009] In a second aspect, an embodiment of the present application provides a device connection method, which is applied to a second electronic device, and the method includes:

[0010] Receiving relay request information sent by the first electronic device;

[0011] sending the device information of the second electronic device to the first electronic device, so that the first electronic device sends the device information of the second electronic device to a wireless electronic device wirelessly connected to the first electronic device; or,

[0012] receiving device information of a wireless electronic device wirelessly connected to the first electronic device and sent by the first electronic device;

[0013] A wireless connection is established with the wireless electronic device.

[0014] In a third aspect, an embodiment of the present application provides a device connection apparatus, which is applied to a first electronic device, and the device includes:

[0015] A first sending module, configured to send a relay request message to a second electronic device, wherein the relay request message carries first device information of the first electronic device;

[0016] A second sending module is configured to send the device information of the second electronic device to a wireless electronic device wirelessly connected to the first electronic device when receiving the relay response information of the second electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device; or

[0017] The second sending module is used to send device information of a wireless electronic device wirelessly connected to the first electronic device to the second electronic device when receiving the relay response information of the second electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

[0018] In a fourth aspect, an embodiment of the present application provides a device connection apparatus, which is applied to a second electronic device, and the device includes:

[0019] A receiving module, used for receiving the relay request information sent by the first electronic device;

[0020] A third sending module is used to send the device information of the second electronic device to the first electronic device, so that the first electronic device sends the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device; or

[0021] The receiving module is further used to receive device information of a wireless electronic device wirelessly connected to the first electronic device and sent by the first electronic device;

[0022] The connection module is used to establish a wireless connection with the wireless electronic device.

[0023] In a fifth aspect, an embodiment of the present application provides an electronic device, which includes a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the program or instructions are executed by the processor, the steps of the method described in the first aspect are implemented.

[0024] In a sixth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.

[0025] In a seventh aspect, an embodiment of the present application provides a chip, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the method described in the first aspect.

[0026] In an eighth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the method described in the first aspect.

[0027] In an embodiment of the present application, a relay request message is sent to a second electronic device, and the relay request message carries the first device information of the first electronic device; when a relay response message is received from the second electronic device, the device information of the second electronic device is sent to the wireless electronic device wirelessly connected to the first electronic device, so as to establish a wireless connection between the wireless electronic device and the second electronic device; a seamless connection between the wireless electronic device and the second electronic device is achieved, avoiding the tedious operation of manual disconnection and reconnection by the user. Alternatively, when a relay response message is received from the second electronic device, the device information of the wireless electronic device wirelessly connected to the first electronic device is sent to the second electronic device, so as to establish a wireless connection between the wireless electronic device and the second electronic device. When the user switches applications between different devices, there is no need to manually manage the connection of the wireless device, which improves the convenience and fluency of the user experience, and the automated device connection process reduces the user waiting time and improves the efficiency of the application relay process. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] Figure 1 is a flow chart of a device connection method provided in an embodiment of the present application;

[0029] Figure 2 is a schematic diagram of a Bluetooth headset connection method provided in an embodiment of the present application;

[0030] Figure 3 is a schematic diagram of a smart watch connection method provided in an embodiment of the present application;

[0031] Figure 4is a flow chart of a device connection method provided in an embodiment of the present application;

[0032] Figure 5 is a schematic diagram of a television connection method provided in an embodiment of the present application;

[0033] Figure 6 is a structural diagram of a device connection device provided in an embodiment of the present application;

[0034] Figure 7 is a structural diagram of a device connection device provided in an embodiment of the present application;

[0035] Figure 8 It is one of the hardware structure diagrams of the electronic device according to the embodiment of the present application;

[0036] Fig. 9 This is the second schematic diagram of the hardware structure of the electronic device according to the embodiment of the present application. DETAILED DESCRIPTION

[0037] The following will be combined with the drawings of the embodiments of the present application to clearly describe the technical solutions of the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all of the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present application belong to the scope of protection of this application.

[0038] The terms "first", "second", etc. in the specification and claims of this application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.

[0039] In response to the problems arising in the related art, the embodiments of the present application provide a device connection method, apparatus, electronic device and storage medium, which can solve the problem that the current operation steps of cross-device application relay in the related art are relatively cumbersome.

[0040] The device connection method provided in the embodiment of the present application is described in detail below through specific embodiments and their application scenarios in conjunction with the accompanying drawings.

[0041] Figure 1 A flowchart of a device connection method provided in an embodiment of the present application.

[0042] like Figure 1 As shown, the device connection method may include steps 110 to 130, and the method is applied to a device connection device, as shown below:

[0043] Step 110, sending a relay request message to a second electronic device, wherein the relay request message carries first device information of the first electronic device;

[0044] Relay request information: refers to request information sent by the first electronic device to the second electronic device, which is used to request to continue using the current application on the second electronic device, that is, to use the application relay function.

[0045] The relay request information is a data structure used to transfer application status and related information between devices. These parameters help the second electronic device to correctly take over the application and maintain the consistency of user operations.

[0046] The relay request information may include at least one of the following: application identification information, device identification information, application state information, user identification information, wireless device identification, and a timestamp.

[0047] The application identification information can be a string that identifies the unique identifier of the application being relayed, usually the package name or application ID of the application. Example: com.example.myapp.

[0048] The device identification information can be a string that identifies the unique identifier of the device that initiates the relay request. Example: device_123456.

[0049] The application status information can be a JSON object, which contains detailed information about the current status of the application, such as the current page, editing content, user operation history, etc.

[0050] The user identification information can be a string that identifies the unique identifier of the current user, which is used to ensure the security of the relay operation and user consistency. Example: user_789012.

[0051] The wireless device identifier may be a Boolean value or a JSON object, which identifies whether the first electronic device is using the wireless electronic device. If it is a Boolean value, it indicates whether it is in use; if it is a JSON object, it may contain more detailed information.

[0052] Timestamp, which identifies the time when the relay request was initiated, and is used to record and sort relay events. Example: 2024-10-01T12:34:56.

[0053] The app relay feature relies on near-field connections between devices, usually implemented through Bluetooth, Wi-Fi Direct, or other near-field communication technologies. The resident dock service is responsible for maintaining and managing these connections. App relay is usually triggered when the user is performing certain operations, such as editing a document, viewing a detail page, or performing other scenarios that require continuous operations, to ensure that the application state can be seamlessly continued when the user switches devices.

[0054] Wireless device information, in the application relay request, identifies whether the first electronic device is using a wireless electronic device. Wireless device information can help the second electronic device correctly handle the interaction with these devices when taking over the application, ensuring consistency of user experience.

[0055] Scenario 1: A user uses a stylus pen to edit a document on a first electronic device. At this time, the application relay request will indicate that the stylus pen is being used. When the user switches to a second electronic device, the second electronic device will continue to support stylus pen input to ensure the continuity of the editing experience.

[0056] Scenario 2: The user listens to music through a Bluetooth headset on the first electronic device. At this time, the application relay request will indicate that the Bluetooth headset is being used. When the user switches to the second electronic device, the second electronic device will continue to play music through the Bluetooth headset to ensure seamless switching of audio output. Figure 2 shown.

[0057] The application relay function enables seamless switching of application experience between different devices through near-field connection and transfer of application status between devices. The wireless device identifier in the request parameter helps ensure that the interaction with these devices can be correctly continued when switching devices, thereby improving the user experience.

[0058] First device information: refers to relevant information of the first electronic device, including: Bluetooth information, device identification information, device model, operating system version, etc. of the first device.

[0059] In addition, the relay request information may also carry wireless device information of the wireless electronic device. Wireless electronic device: refers to an external device wirelessly connected to the first electronic device, such as a Bluetooth headset. Wireless device information: refers to relevant information of the wireless electronic device, including: device identification information, device model, Bluetooth address, etc.

[0060] Step 120, upon receiving the relay response information from the second electronic device, sending the device information of the second electronic device to a wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device; or,

[0061] Relay response information: refers to the response information of the second electronic device to the relay request information, indicating whether the relay request is accepted.

[0062] The Bluetooth information may include at least one of the following: Bluetooth address, Bluetooth version, Bluetooth status, a list of connected Bluetooth devices, and Bluetooth device capabilities.

[0063] Bluetooth status, which identifies the current Bluetooth status of the second electronic device, that is, whether the Bluetooth function is turned on. Example: true (Bluetooth is turned on), false (Bluetooth is not turned on), to ensure that the second electronic device can correctly handle the interaction with the Bluetooth device when taking over the application.

[0064] The list of connected Bluetooth devices can be an array, which includes currently connected Bluetooth devices, such as Bluetooth headsets, Bluetooth keyboards, Bluetooth mice, etc.

[0065] Bluetooth device capabilities, which describe the capabilities of the connected Bluetooth device on the second electronic device, such as audio output, input device type, etc.

[0066] The Bluetooth information of the second electronic device plays a vital role in the application relay process. By providing detailed Bluetooth status, list of connected devices, device capabilities, battery level, connection status and priority, the second electronic device can ensure that when taking over the application, it correctly handles the interaction with the Bluetooth device, thereby improving the consistency and continuity of the user experience.

[0067] After receiving the relay response information from the second electronic device, the first electronic device performs the next operation according to the response information. If the relay response information indicates acceptance of the relay request, the first electronic device sends the Bluetooth information of the second electronic device to the wireless electronic device so that the wireless electronic device and the second electronic device establish a wireless connection.

[0068] Step 130: upon receiving the relay response information from the second electronic device, sending device information of a wireless electronic device wirelessly connected to the first electronic device to the second electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

[0069] By carrying the wireless device information in the relay request information and processing the Bluetooth information in the relay response information, a seamless connection between the wireless electronic device and the second electronic device is achieved, avoiding the tedious operation of manual disconnection and reconnection by the user.

[0070] When users switch applications between different devices, they do not need to manually manage the connection of wireless devices, which improves the convenience and fluency of the user experience; by automatically processing the Bluetooth information exchange between devices, the ability of different devices to work together is enhanced, making application relay more intelligent and automated; the automated device connection process reduces user waiting time and improves the efficiency of the application relay process, allowing users to continue using applications faster. As a result, seamless relay of application software and its related hardware devices between different devices is achieved, significantly improving the user experience and the efficiency of device collaboration.

[0071] In a possible embodiment, step 120 includes:

[0072] When receiving the relay response information from the second electronic device, sending service relay information to the wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device disconnects the wireless connection with the first electronic device according to the service relay information and starts Bluetooth broadcasting;

[0073] receiving Bluetooth information of the second electronic device;

[0074] The Bluetooth information of the second electronic device is sent to the wireless electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

[0075] Service relay information: refers to information used to instruct the wireless electronic device to disconnect the wireless connection with the first electronic device and start Bluetooth broadcasting.

[0076] Bluetooth broadcast: refers to a Bluetooth device actively sending Bluetooth signals to the surrounding area so that other devices can discover and connect to the device.

[0077] After receiving the relay response information from the second electronic device, the first electronic device sends service relay information to the wireless electronic device. The service relay information is used to instruct the wireless electronic device to disconnect the wireless connection with the first electronic device and start Bluetooth broadcasting so that the second electronic device can find and connect to the wireless electronic device.

[0078] The first electronic device receives the Bluetooth information sent by the second electronic device, where the Bluetooth information sent by the second electronic device includes key information such as the Bluetooth address of the second electronic device.

[0079] The first electronic device sends the received Bluetooth information of the second electronic device to the wireless electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

[0080] By sending service relay information, the wireless electronic device can automatically disconnect from the first electronic device and start Bluetooth broadcasting, simplifying the user's manual operation steps; after disconnecting from the first electronic device, the wireless electronic device can automatically establish a connection with the second electronic device, realizing seamless switching between devices and improving the smoothness of the user experience.

[0081] The automated Bluetooth information exchange process reduces user waiting time, improves the efficiency of device collaboration, and enables users to continue using applications more quickly; by automatically processing the connection and disconnection operations between devices, the intelligence level of the devices is enhanced, allowing the devices to better adapt to user needs. As a result, seamless relays between wireless electronic devices are achieved, significantly improving user experience and the efficiency of device collaboration.

[0082] In a possible embodiment, step 130 includes:

[0083] When receiving the relay response information from the second electronic device, outputting first prompt information, wherein the first prompt information is used to prompt whether to authorize the second electronic device to access the wireless electronic device;

[0084] When receiving a confirmation input of the first prompt information, sending service relay information to a wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device disconnects the wireless connection with the first electronic device according to the service relay information and starts Bluetooth broadcasting;

[0085] Receiving Bluetooth information of the wireless electronic device;

[0086] The Bluetooth information of the wireless electronic device is sent to the second electronic device, so that the wireless electronic device can establish a connection with the second electronic device.

[0087] First prompt information: refers to information used to prompt the user whether to authorize the second electronic device to access the wireless electronic device.

[0088] The first prompt information may be a Dock icon, which generally refers to an application icon in a quick launch bar at the bottom or side of the screen in an operating system (such as macOS or some Linux desktop environments). These icons are used to quickly launch applications, switch applications, or display the current status of applications. In the context of application relay, the Dock icon can be used to trigger an application relay operation.

[0089] Confirm input: refers to the user's confirmation operation on the first prompt information, such as clicking the "Confirm" button.

[0090] After receiving the relay response information from the second electronic device, the first electronic device outputs a first prompt message to prompt the user whether to authorize the second electronic device to access the wireless electronic device. The first electronic device waits for the user to confirm the first prompt message. If the user confirms the authorization, the next step is performed.

[0091] After receiving the user's confirmation input, the first electronic device sends service relay information to the wireless electronic device. The service relay information is used to instruct the wireless electronic device to disconnect the wireless connection with the first electronic device and start Bluetooth broadcasting so that the second electronic device can discover and connect to the wireless electronic device.

[0092] The first electronic device receives the Bluetooth information sent by the wireless electronic device, which includes key information such as the Bluetooth address of the wireless electronic device. The first electronic device sends the received Bluetooth information of the wireless electronic device to the second electronic device so that the wireless electronic device can establish a connection with the second electronic device.

[0093] like Figure 3 As shown, the smart watch receives the relay request information sent by the first electronic device, and the relay request information carries the first device information of the first electronic device and the wireless device information of the wireless electronic device. The first electronic device and the wireless electronic device communicate via a wireless connection.

[0094] The first electronic device outputs a first prompt message, prompting the user whether to authorize access to the wireless electronic device, such as a Bluetooth headset, and if the user confirms the authorization, the next step is performed. After receiving the user's confirmation input, the Bluetooth information of the wireless electronic device is sent to the smart watch.

[0095] By outputting a first prompt message and receiving the user's confirmation input, the user's authorized control over device access is ensured, thereby enhancing the user's sense of control over device connection; after the user confirms the authorization, the wireless electronic device can automatically disconnect from the first electronic device and start Bluetooth broadcasting, thereby simplifying the user's manual operation steps; after the wireless electronic device disconnects from the first electronic device, it can automatically establish a connection with the second electronic device, thereby achieving seamless switching between devices and improving the smoothness of the user experience.

[0096] The automated Bluetooth information exchange process reduces user waiting time, improves the efficiency of device collaboration, and enables users to continue using applications more quickly. This enables seamless relay of wireless electronic devices between different devices and ensures user authorization control over device access, significantly improving user experience and the efficiency of device collaboration.

[0097] Wherein, the wireless electronic device includes at least one of the following:

[0098] Bluetooth headphones, stylus, smartwatch, Bluetooth speakers and TV.

[0099] Bluetooth headset: A Bluetooth headset is a headset that is wirelessly connected to a device (such as a mobile phone, tablet, computer, etc.) via Bluetooth technology. Users can listen to audio content such as music, phone calls, etc. through Bluetooth headsets.

[0100] Stylus: A stylus is an input tool that connects to a touch device via Bluetooth or other wireless technologies. Users can use the stylus to write, draw, and perform other operations on the touch screen.

[0101] Smartwatch: A smartwatch is a wearable device that connects to a smartphone or other device via Bluetooth or other wireless technologies. Smartwatches usually have functions such as time display, health monitoring, and notification reminders.

[0102] Bluetooth speakers: Bluetooth speakers are audio output devices that are wirelessly connected to devices (such as mobile phones, tablets, computers, etc.) through Bluetooth technology. Users can play audio content such as music, movies, etc. through Bluetooth speakers.

[0103] TV: A TV is a display device that connects to a device via Bluetooth or other wireless technologies. Users can watch video content, play games, etc. on a TV.

[0104] These wireless electronic devices are connected to devices via Bluetooth or other wireless technologies, providing various functions such as audio transmission, touch input, health monitoring, notification reminders, audio output, video playback, etc. Through the above technical solutions, these wireless electronic devices can be seamlessly relayed between different devices, and the user's authorized control over device access is ensured, which significantly improves the user experience and the efficiency of device collaboration.

[0105] In an embodiment of the present application, a relay request message is sent to a second electronic device, and the relay request message carries the first device information of the first electronic device; when a relay response message is received from the second electronic device, the device information of the second electronic device is sent to the wireless electronic device wirelessly connected to the first electronic device, so as to establish a wireless connection between the wireless electronic device and the second electronic device; a seamless connection between the wireless electronic device and the second electronic device is achieved, avoiding the tedious operation of manual disconnection and reconnection by the user. Alternatively, when a relay response message is received from the second electronic device, the device information of the wireless electronic device wirelessly connected to the first electronic device is sent to the second electronic device, so as to establish a wireless connection between the wireless electronic device and the second electronic device. When the user switches applications between different devices, there is no need to manually manage the connection of the wireless device, which improves the convenience and fluency of the user experience, and the automated device connection process reduces the user waiting time and improves the efficiency of the application relay process.

[0106] Figure 4 A flowchart of a device connection method provided in an embodiment of the present application.

[0107] like Figure 4 As shown, the device connection method may include steps 410 to 440, and the method is applied to a device connection device, as shown below:

[0108] Step 410: receiving relay request information sent by the first electronic device.

[0109] The relay request information may carry the first device information of the first electronic device and the wireless device information of the wireless electronic device; the first electronic device and the wireless electronic device information are wirelessly connected;

[0110] Relay request information: refers to request information sent by the first electronic device to the second electronic device, used to request to continue using the current application on the second electronic device.

[0111] First device information: refers to relevant information of the first electronic device, such as device model, operating system version, etc.

[0112] Wireless electronic device: refers to an external device that is wirelessly connected to the first electronic device, such as a Bluetooth headset.

[0113] Wireless device information: refers to the relevant information of wireless electronic devices, such as device model, Bluetooth address, etc.

[0114] The second electronic device receives the relay request information sent by the first electronic device. The relay request information carries the first device information of the first electronic device and the wireless device information of the wireless electronic device. The first electronic device and the wireless electronic device communicate via a wireless connection.

[0115] Step 420: Send the device information of the second electronic device to the first electronic device, so that the first electronic device can send the device information of the second electronic device to a wireless electronic device wirelessly connected to the first electronic device.

[0116] The device information of the second electronic device includes: Bluetooth information of the second electronic device.

[0117] Bluetooth information: refers to the Bluetooth-related information of the device, such as Bluetooth address, Bluetooth version, etc.

[0118] Wherein, step 420 may include: sending relay response information to the first electronic device, and sending device information of the second electronic device to the first electronic device.

[0119] The second electronic device sends a relay response message to the first electronic device, indicating that the relay request is accepted. At the same time, the second electronic device sends the Bluetooth information of the second electronic device to the first electronic device, so that the first electronic device sends the information to the wireless electronic device, thereby establishing a wireless connection between the wireless electronic device and the second electronic device.

[0120] The second electronic device receives the application relay request from the first electronic device through a resident base service (such as Nearby Connections). The second electronic device checks whether it has the conditions for relaying, including device status, application status, user permissions, etc. The second electronic device confirms whether it is the target relay terminal, that is, the device to which the user wants to relay the application. For example, the device status and application status include whether the device is idle and whether the application is installed.

[0121] In a possible embodiment, step 420 includes:

[0122] Outputting second prompt information, where the second prompt information is used to prompt whether to authorize access to the wireless electronic device;

[0123] When a confirmation input of the second prompt information is received, Bluetooth information of the second electronic device is sent to the first electronic device.

[0124] Second prompt information: refers to information used to prompt the user whether to authorize access to the wireless electronic device.

[0125] Confirm input: refers to the user's confirmation operation on the second prompt information, such as clicking the "Confirm" button.

[0126] The second electronic device outputs second prompt information, prompting the user whether to authorize access to the wireless electronic device.

[0127] When the second electronic device successfully negotiates with the first electronic device and agrees to relay, the desktop Dock bar of the second electronic device will display a second prompt message to prompt the user that the application relay is about to begin. The second prompt message may specifically be an application relay icon.

[0128] The second electronic device displays a special icon on the Dock bar, indicating that the application relay is about to begin, and notifying the user that the application relay is about to begin. The user can click the icon to continue the relay operation.

[0129] The second electronic device waits for the user to confirm the second prompt information. If the user confirms the authorization, the next step is performed. After receiving the user's confirmation input, the second electronic device sends a relay response message to the first electronic device, indicating that the relay request is accepted. At the same time, the second electronic device sends the Bluetooth information of the second electronic device to the first electronic device, so that the first electronic device sends the information to the wireless electronic device, thereby establishing a wireless connection between the wireless electronic device and the second electronic device.

[0130] By outputting a second prompt message and receiving the user's confirmation input, the user's authorized control over device access is ensured, thereby enhancing the user's sense of control over device connection; after the user confirms the authorization, the second electronic device can automatically process the relay request between devices, simplifying the user's manual operation steps; after the wireless electronic device disconnects from the first electronic device, it can automatically establish a connection with the second electronic device, achieving seamless switching between devices and improving the smoothness of the user experience.

[0131] For example, when a user uses a video application installed on a mobile phone, he often needs to switch applications between different devices, such as switching from a mobile phone to a pad. In order to achieve seamless relay of applications and related hardware devices (such as TV) between different devices, the first electronic device (mobile phone) and the second electronic device (pad) need to complete the access exchange of the wireless device (such as TV) during the application relay process.

[0132] The first electronic device (mobile phone) sends a relay request message to the second electronic device (pad). The message carries the first device information of the first electronic device and the wireless device information of the TV. The first electronic device and the wireless device communicate via a wireless connection (such as Wi-Fi).

[0133] The user opens a video application on the mobile phone and chooses to cast the screen to the TV. The mobile phone and TV are connected via Wi-Fi to play the video. The user triggers an application relay request on the mobile phone, hoping to relay the video application to the Pad. The Pad receives the relay request information sent by the mobile phone via Wi-Fi, which contains the device information of the mobile phone and the device information of the TV.

[0134] The Pad displays a second prompt message on the screen, prompting the user whether to authorize the Pad to access the TV. The user confirms the authorization through the touch screen or button on the Pad. The Pad sends a relay response message to the mobile phone, indicating that it accepts the relay request. At the same time, the Pad sends the Pad's Bluetooth information to the mobile phone. After the mobile phone receives the Pad's relay response message and the Pad's Bluetooth information, it sends the Pad's Bluetooth information to the TV, so that the TV and the Pad establish a wireless connection. The Pad takes over the video playback and continues to play the video on the TV, realizing seamless relay between applications and devices.

[0135] By outputting the second prompt information and receiving the user's confirmation input, the user's authorization control over the device access is ensured, which enhances the user's control over the device connection; after the user confirms the authorization, the Pad end can automatically process the relay request between devices, simplifying the user's manual operation steps. After the TV is disconnected from the mobile phone, it can automatically establish a connection with the Pad, realizing seamless switching between devices and improving the smoothness of the user experience.

[0136] The automated Bluetooth information exchange process reduces user waiting time, improves the efficiency of device collaboration, and enables users to continue using applications more quickly. By automatically handling the connection and disconnection operations between devices, the intelligence level of the Pad end is enhanced, allowing the device to better adapt to the user's usage needs, achieving seamless relay of mobile phone video applications on the Pad end, and completing device relay with the TV, significantly improving the user experience and the efficiency of device collaboration.

[0137] Step 430: Receive device information of a wireless electronic device wirelessly connected to the first electronic device and sent by the first electronic device.

[0138] Device information of wireless electronic devices, including: Bluetooth information of wireless electronic devices.

[0139] By receiving relay request information and sending relay response information, the second electronic device can automatically process the relay request between devices, simplifying the user's manual operation steps; after the wireless electronic device disconnects from the first electronic device, it can automatically establish a connection with the second electronic device, realizing seamless switching between devices and improving the smoothness of the user experience; the automated Bluetooth information exchange process reduces user waiting time, improves the efficiency of device collaboration, and enables users to continue using applications faster.

[0140] By automatically processing the connection and disconnection operations between devices, the intelligence level of the device is enhanced, so that the device can better adapt to the user's usage needs. The embodiments of the present application are applicable to a variety of wireless electronic devices, including Bluetooth headsets, styluses, smart watches, Bluetooth speakers and TVs, etc., and have wide applicability and flexibility. As a result, seamless relay between various wireless electronic devices is achieved, and the user's authorized control of device access is ensured, which significantly improves the user experience and the efficiency of device collaboration.

[0141] Step 440: Establish a wireless connection with the wireless electronic device.

[0142] In an embodiment of the present application, a relay request message sent by the first electronic device is received; the device information of the second electronic device is sent to the first electronic device, so that the first electronic device sends the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device; after the first electronic device receives the device information of the second electronic device, the device information of the second electronic device can be forwarded to the wireless electronic device wirelessly connected to the first electronic device. In this way, the wireless electronic device can identify and possibly establish a connection with the second electronic device. Alternatively, the device information of the wireless electronic device wirelessly connected to the first electronic device sent by the first electronic device is received; the second electronic device can identify and establish a connection with the wireless electronic device by receiving the device information of the wireless electronic device, providing a basis for direct communication between the second electronic device and the wireless electronic device, establishing a wireless connection with the wireless electronic device, and the second electronic device can directly communicate with the wireless electronic device, realizing seamless collaboration between devices, thereby reducing user waiting time through an automated device connection process and improving the efficiency of the application relay process.

[0143] The device connection method provided in the embodiment of the present application can be executed by a device connection device. In the embodiment of the present application, the device connection method executed by the device connection device is taken as an example to illustrate the device connection device provided in the embodiment of the present application.

[0144] Figure 6 600 is a block diagram of a device connection apparatus provided in an embodiment of the present application, the device 600 includes:

[0145] A first sending module 610, configured to send a relay request message to a second electronic device, wherein the relay request message carries first device information of the first electronic device;

[0146] The second sending module 620 is used to send the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device when receiving the relay response information of the second electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device; or

[0147] The second sending module 620 is used to send device information of a wireless electronic device wirelessly connected to the first electronic device to the second electronic device when receiving the relay response information from the second electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

[0148] In a possible embodiment, the second sending module 620 is specifically configured to:

[0149] When receiving the relay response information from the second electronic device, sending service relay information to the wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device disconnects the wireless connection with the first electronic device according to the service relay information and starts Bluetooth broadcasting;

[0150] receiving Bluetooth information of the second electronic device;

[0151] The Bluetooth information of the second electronic device is sent to the wireless electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

[0152] In a possible embodiment, the second sending module 620 is specifically configured to:

[0153] When receiving the relay response information from the second electronic device, outputting first prompt information, wherein the first prompt information is used to prompt whether to authorize the second electronic device to access the wireless electronic device;

[0154] When receiving a confirmation input of the first prompt information, sending service relay information to a wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device disconnects the wireless connection with the first electronic device according to the service relay information and starts Bluetooth broadcasting;

[0155] Receiving Bluetooth information from the wireless electronic device;

[0156] The Bluetooth information of the wireless electronic device is sent to the second electronic device, so that the wireless electronic device can establish a connection with the second electronic device.

[0157] In an embodiment of the present application, a relay request message is sent to a second electronic device, and the relay request message carries the first device information of the first electronic device; when a relay response message is received from the second electronic device, the device information of the second electronic device is sent to the wireless electronic device wirelessly connected to the first electronic device, so as to establish a wireless connection between the wireless electronic device and the second electronic device; a seamless connection between the wireless electronic device and the second electronic device is achieved, avoiding the tedious operation of manual disconnection and reconnection by the user. Alternatively, when a relay response message is received from the second electronic device, the device information of the wireless electronic device wirelessly connected to the first electronic device is sent to the second electronic device, so as to establish a wireless connection between the wireless electronic device and the second electronic device. When the user switches applications between different devices, there is no need to manually manage the connection of the wireless device, which improves the convenience and fluency of the user experience, and the automated device connection process reduces the user waiting time and improves the efficiency of the application relay process.

[0158] Figure 7700 is a block diagram of a device connection apparatus provided in an embodiment of the present application, the device 700 includes:

[0159] The receiving module 710 is used to receive the relay request information sent by the first electronic device;

[0160] The third sending module 720 is used to send the device information of the second electronic device to the first electronic device, so that the first electronic device sends the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device; or

[0161] The receiving module 710 is further configured to receive device information of a wireless electronic device wirelessly connected to the first electronic device and sent by the first electronic device;

[0162] The connection module 730 is used to establish a wireless connection with the wireless electronic device.

[0163] In a possible embodiment, the third sending module 720 is specifically configured to:

[0164] Outputting second prompt information, where the second prompt information is used to prompt whether to authorize access to the wireless electronic device;

[0165] When a confirmation input of the second prompt information is received, Bluetooth information of the second electronic device is sent to the first electronic device.

[0166] In an embodiment of the present application, a relay request message sent by the first electronic device is received; the device information of the second electronic device is sent to the first electronic device, so that the first electronic device sends the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device; after the first electronic device receives the device information of the second electronic device, the device information of the second electronic device can be forwarded to the wireless electronic device wirelessly connected to the first electronic device. In this way, the wireless electronic device can identify and possibly establish a connection with the second electronic device. Alternatively, the device information of the wireless electronic device wirelessly connected to the first electronic device sent by the first electronic device is received; the second electronic device can identify and establish a connection with the wireless electronic device by receiving the device information of the wireless electronic device, providing a basis for direct communication between the second electronic device and the wireless electronic device, establishing a wireless connection with the wireless electronic device, and the second electronic device can directly communicate with the wireless electronic device, realizing seamless collaboration between devices, thereby reducing user waiting time through an automated device connection process and improving the efficiency of the application relay process.

[0167] The device connection device in the embodiment of the present application can be an electronic device, or a component in the electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal, or it can be other devices other than a terminal. Exemplarily, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted electronic device, a mobile Internet device (Mobile Internet Device, MID), an augmented reality (augmented reality, AR) / virtual reality (virtual reality, VR) device, a robot, a wearable device, an ultra-mobile personal computer (ultra-mobile personal computer, UMPC), a netbook or a personal digital assistant (personal digital assistant, PDA), etc., and can also be a server, a network attached storage (Network Attached Storage, NAS), a personal computer (personal computer, PC), a television (television, TV), a teller machine or a self-service machine, etc., which is not specifically limited in the embodiment of the present application.

[0168] The device connection device of the embodiment of the present application may be a device having an action system. The action system may be an Android action system, an iOS action system, or other possible action systems, which are not specifically limited in the embodiment of the present application.

[0169] The device connection apparatus provided in the embodiment of the present application can implement each process implemented in the above method embodiment, and will not be described again here to avoid repetition.

[0170] Alternatively, if Figure 8 As shown, an embodiment of the present application also provides an electronic device 810, including a processor 811, a memory 812, and a program or instruction stored in the memory 812 and executable on the processor 811. When the program or instruction is executed by the processor 811, each step of any of the above-mentioned device connection method embodiments is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0171] It should be noted that the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.

[0172] Fig. 9 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of the present application.

[0173] The electronic device 900 includes but is not limited to: a radio frequency unit 901, a network module 902, an audio output unit 903, an input unit 904, a sensor 905, a display unit 906, a user input unit 907, an interface unit 908, a memory 909, and a processor 910 and other components.

[0174] Those skilled in the art will appreciate that the electronic device 900 may also include a power source (such as a battery) for supplying power to each component, and the power source may be logically connected to the processor 910 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Fig. 9 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.

[0175] The network module 902 is used to send a relay request message to the second electronic device, where the relay request message carries the first device information of the first electronic device;

[0176] The network module 902 is further configured to, upon receiving the relay response information from the second electronic device, send the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device; or

[0177] The network module 902 is further used to send device information of a wireless electronic device wirelessly connected to the first electronic device to the second electronic device upon receiving the relay response information from the second electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

[0178] Optionally, the network module 902 is further configured to, upon receiving the relay response information from the second electronic device, send service relay information to the wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device disconnects the wireless connection with the first electronic device according to the service relay information and starts Bluetooth broadcasting;

[0179] The network module 902 is further used to receive Bluetooth information of the second electronic device;

[0180] The network module 902 is further used to send the Bluetooth information of the second electronic device to the wireless electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

[0181] Optionally, the network module 902 is further configured to output first prompt information when receiving the relay response information of the second electronic device, wherein the first prompt information is used to prompt whether to authorize the second electronic device to access the wireless electronic device;

[0182] The network module 902 is further configured to, upon receiving a confirmation input for the first prompt information, send service relay information to a wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device disconnects the wireless connection with the first electronic device according to the service relay information and starts Bluetooth broadcasting;

[0183] The network module 902 is also used to receive Bluetooth information of the wireless electronic device;

[0184] The network module 902 is further used to send the Bluetooth information of the wireless electronic device to the second electronic device, so that the wireless electronic device can establish a connection with the second electronic device.

[0185] In an embodiment of the present application, a relay request message is sent to a second electronic device, and the relay request message carries the first device information of the first electronic device; when a relay response message is received from the second electronic device, the device information of the second electronic device is sent to the wireless electronic device wirelessly connected to the first electronic device, so as to establish a wireless connection between the wireless electronic device and the second electronic device; a seamless connection between the wireless electronic device and the second electronic device is achieved, avoiding the tedious operation of manual disconnection and reconnection by the user. Alternatively, when a relay response message is received from the second electronic device, the device information of the wireless electronic device wirelessly connected to the first electronic device is sent to the second electronic device, so as to establish a wireless connection between the wireless electronic device and the second electronic device. When the user switches applications between different devices, there is no need to manually manage the connection of the wireless device, which improves the convenience and fluency of the user experience, and the automated device connection process reduces the user waiting time and improves the efficiency of the application relay process.

[0186] Alternatively, the network module 902 is configured to receive relay request information sent by the first electronic device;

[0187] The network module 902 is further configured to send the device information of the second electronic device to the first electronic device, so that the first electronic device sends the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device; or

[0188] The network module 902 is further configured to receive device information of a wireless electronic device wirelessly connected to the first electronic device and sent by the first electronic device;

[0189] The processor 910 is configured to establish a wireless connection with the wireless electronic device.

[0190] Optionally, the display unit 906 is used to output second prompt information, where the second prompt information is used to prompt whether to authorize access to the wireless electronic device;

[0191] The network module 902 is further configured to send the Bluetooth information of the second electronic device to the first electronic device upon receiving a confirmation input for the second prompt information.

[0192] In an embodiment of the present application, a relay request message sent by the first electronic device is received; the device information of the second electronic device is sent to the first electronic device, so that the first electronic device sends the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device; after the first electronic device receives the device information of the second electronic device, the device information of the second electronic device can be forwarded to the wireless electronic device wirelessly connected to the first electronic device. In this way, the wireless electronic device can identify and possibly establish a connection with the second electronic device. Alternatively, the device information of the wireless electronic device wirelessly connected to the first electronic device sent by the first electronic device is received; the second electronic device can identify and establish a connection with the wireless electronic device by receiving the device information of the wireless electronic device, providing a basis for direct communication between the second electronic device and the wireless electronic device, establishing a wireless connection with the wireless electronic device, and the second electronic device can directly communicate with the wireless electronic device, realizing seamless collaboration between devices, thereby reducing user waiting time through an automated device connection process and improving the efficiency of the application relay process.

[0193] It should be understood that in the embodiment of the present application, the input unit 904 may include a graphics processor (Graphics Processing Unit, GPU) 9041 and a microphone 9042, and the graphics processor 9041 processes the image data of the static picture or video image obtained by the image capture device (such as a camera) in the video image capture mode or the image capture mode. The display unit 906 may include a display panel 9061, and the display panel 9061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 907 includes at least one of a touch panel 9071 and other input devices 9072. The touch panel 9071 is also called a touch screen. The touch panel 9071 may include two parts: a touch detection device and a touch controller. Other input devices 9072 may include, but are not limited to, a physical keyboard, a function key (such as a volume control button, a switch button, etc.), a trackball, a mouse, and an action rod, which will not be repeated here. The memory 909 can be used to store software programs and various data, including but not limited to applications and action systems. The processor 910 may integrate an application processor and a modem processor, wherein the application processor mainly processes the action system, user pages and application programs, and the modem processor mainly processes wireless communications. It is understandable that the modem processor may not be integrated into the processor 910.

[0194] The memory 909 can be used to store software programs and various data. The memory 909 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 909 may include a volatile memory or a non-volatile memory, or the memory x09 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory 909 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.

[0195] The processor 910 may include one or more processing units; optionally, the processor 910 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 910.

[0196] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the above-mentioned device connection method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0197] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.

[0198] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned device connection method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0199] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.

[0200] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned device connection method embodiment and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0201] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.

[0202] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.

[0203] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.

Claims

1. A device connection method, characterized in that: Applied to a first electronic device, the method includes: Sending a relay request message to a second electronic device, where the relay request message carries first device information of the first electronic device; When receiving the relay response information from the second electronic device, sending the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device; or When the relay response information of the second electronic device is received, the device information of the wireless electronic device wirelessly connected to the first electronic device is sent to the second electronic device so that the wireless electronic device can establish a wireless connection with the second electronic device.

2. The method according to claim 1, characterized in that The method of sending the device information of the second electronic device to a wireless electronic device wirelessly connected to the first electronic device upon receiving the relay response information of the second electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device, includes: When receiving the relay response information from the second electronic device, sending service relay information to the wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device disconnects the wireless connection with the first electronic device according to the service relay information and starts Bluetooth broadcasting; receiving Bluetooth information of the second electronic device; The Bluetooth information of the second electronic device is sent to the wireless electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

3. The method according to claim 1, characterized in that The method of sending device information of a wireless electronic device wirelessly connected to the first electronic device to the second electronic device upon receiving the relay response information from the second electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device, includes: When receiving the relay response information from the second electronic device, outputting first prompt information, wherein the first prompt information is used to prompt whether to authorize the second electronic device to access the wireless electronic device; When receiving a confirmation input of the first prompt information, sending service relay information to a wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device disconnects the wireless connection with the first electronic device according to the service relay information and starts Bluetooth broadcasting; Receiving Bluetooth information from the wireless electronic device; The Bluetooth information of the wireless electronic device is sent to the second electronic device, so that the wireless electronic device can establish a connection with the second electronic device.

4. A device connection method, characterized in that: Applied to a second electronic device, the method includes: Receiving relay request information sent by the first electronic device; sending the device information of the second electronic device to the first electronic device, so that the first electronic device sends the device information of the second electronic device to a wireless electronic device wirelessly connected to the first electronic device; or, receiving device information of a wireless electronic device wirelessly connected to the first electronic device and sent by the first electronic device; A wireless connection is established with the wireless electronic device.

5. The method according to claim 4, characterized in that The sending the device information of the second electronic device to the first electronic device includes: Outputting second prompt information, where the second prompt information is used to prompt whether to authorize access to the wireless electronic device; When a confirmation input of the second prompt information is received, Bluetooth information of the second electronic device is sent to the first electronic device.

6. A device connection device, characterized in that: Applied to a first electronic device, the device comprises: A first sending module, configured to send a relay request message to a second electronic device, wherein the relay request message carries first device information of the first electronic device; A second sending module is configured to send the device information of the second electronic device to a wireless electronic device wirelessly connected to the first electronic device when receiving the relay response information of the second electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device; or The second sending module is used to send device information of a wireless electronic device wirelessly connected to the first electronic device to the second electronic device when receiving the relay response information of the second electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

7. The device according to claim 6, characterized in that The second sending module is specifically used for: When receiving the relay response information from the second electronic device, sending service relay information to the wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device disconnects the wireless connection with the first electronic device according to the service relay information and starts Bluetooth broadcasting; receiving Bluetooth information of the second electronic device; The Bluetooth information of the second electronic device is sent to the wireless electronic device, so that the wireless electronic device can establish a wireless connection with the second electronic device.

8. The device according to claim 6, characterized in that The second sending module is specifically used for: When receiving the relay response information from the second electronic device, outputting first prompt information, wherein the first prompt information is used to prompt whether to authorize the second electronic device to access the wireless electronic device; When receiving a confirmation input of the first prompt information, sending service relay information to a wireless electronic device wirelessly connected to the first electronic device, so that the wireless electronic device disconnects the wireless connection with the first electronic device according to the service relay information and starts Bluetooth broadcasting; Receiving Bluetooth information from the wireless electronic device; The Bluetooth information of the wireless electronic device is sent to the second electronic device, so that the wireless electronic device can establish a connection with the second electronic device.

9. A device connection device, characterized in that: Applied to a second electronic device, the device comprises: A receiving module, used for receiving the relay request information sent by the first electronic device; A third sending module is used to send the device information of the second electronic device to the first electronic device, so that the first electronic device sends the device information of the second electronic device to the wireless electronic device wirelessly connected to the first electronic device; or The receiving module is further used to receive device information of a wireless electronic device wirelessly connected to the first electronic device and sent by the first electronic device; The connection module is used to establish a wireless connection with the wireless electronic device.

10. The device according to claim 9, characterized in that The third sending module is specifically used for: Outputting second prompt information, where the second prompt information is used to prompt whether to authorize access to the wireless electronic device; When a confirmation input of the second prompt information is received, Bluetooth information of the second electronic device is sent to the first electronic device.

11. An electronic device, characterized in that: The method comprises a processor and a memory, wherein the memory stores a program or instruction that can be run on the processor, and when the program or instruction is executed by the processor, the steps of the method according to any one of claims 1 to 5 are implemented.

12. A readable storage medium, characterized in that: The readable storage medium stores a program or instruction, and when the program or instruction is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.