Data sharing method and electronic equipment
By displaying multiple devices in the sharing interface and establishing multiple physical links, the problem of poor user experience when sharing data with multiple devices in the prior art is solved, and a more efficient data sharing experience is achieved.
Patent Information
- Application Number
- CN202411988613.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-13
- Publication Date
- 2025-05-06
- Estimated Expiration
- 2044-09-13
AI Technical Summary
When the prior art shares data with multiple devices, the user experience is poor and the sharing strategy is rough. It requires connections with the devices one by one, which is inefficient.
Provide a data sharing method, by displaying multiple devices in the sharing interface and establishing M physical links with M target devices selected by the user, marking that the connection status is being established, improving the user experience.
This enables users to select multiple devices at the same time for data sharing, improves user experience, and creates an effect that supports the establishment of more physical links at the same time.
Smart Images

Figure CN119946909A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computers and terminal technologies, and in particular to a data sharing method and electronic device. Background Art
[0002] Currently, terminals such as smartphones and tablet computers can support users to share data such as pictures and documents with other devices in a wireless manner. For example, users can share pictures and files on terminals such as smartphones with other devices through Wi-Fi connections.
[0003] When users want to share to multiple devices, the current sharing strategy is mostly one-to-one sharing. The user's terminal needs to share to one device before sharing to the second device. The sharing strategy is relatively rough and the user experience is poor. Summary of the invention
[0004] In view of this, the present application provides a data sharing method and an electronic device for improving the user experience when sharing data with multiple devices.
[0005] In order to achieve the above objectives, in a first aspect, an embodiment of the present application provides a data sharing method, which is applied to an electronic device, comprising:
[0006] In response to a first operation, a sharing interface is displayed, wherein a plurality of devices are displayed in the sharing interface, wherein the first operation includes turning on a sharing switch;
[0007] In response to the second operation, M physical links are established with the M target devices respectively, and in the sharing interface, the M target devices are marked as a first state, wherein the second operation indicates that M target devices are selected from a plurality of devices, M is greater than or equal to 2, and the first state is used to indicate that the electronic device is establishing a connection with the corresponding target device;
[0008] After successfully establishing a physical link with a first target device among the M target devices, sending a sharing request to the first target device;
[0009] A message of consent to share returned by the first target device is received, and the shared data is transmitted to the first target device.
[0010] In the data sharing method provided by the embodiment of the present application, the electronic device responds to the operation of the user selecting M target devices from multiple devices in the sharing interface, and respectively establishes M physical links with the M target devices, so that the user can select multiple devices at the same time for data sharing. At the same time, the electronic device marks all the devices selected by the user in the sharing interface as the first state of establishing a connection, so that when the user selects a large number of devices, for example, more than the maximum number of physical links N allowed to be established simultaneously by the electronic device, the electronic device can also show the user that the requests of all the devices selected by the user are being processed (for example, the devices in the queue and the devices being connected are all displayed in the interface as being in the state of establishing a connection, or the devices in the queue and the devices being connected are displayed in different states on the interface, the former is in the connection establishment queue state, and the latter is in the connection establishment state), so as to create the effect that the electronic device supports the establishment of more physical links at the same time, thereby improving the user experience.
[0011] In a possible implementation manner of the first aspect, after successfully establishing a physical link with a first target device among the M target devices, the method further includes:
[0012] authenticating the first target device through a physical link established with the first target device;
[0013] Sending a sharing request to the first target device includes:
[0014] After the first target device is successfully authenticated, a sharing request is sent to the first target device.
[0015] In a possible implementation manner of the first aspect, after successfully establishing a physical link with a first target device among the M target devices, the method further includes:
[0016] In the sharing interface, the first target device is marked as a second state, and the second state is used to indicate that the first target device is in an authentication state or a data transmission preparation state.
[0017] Through the above implementation, the status of each device selected by the user to share data can be dynamically adjusted in the sharing interface to reflect the difference in the interaction process between the electronic device and each device selected by the user, making the multi-channel interaction more realistic.
[0018] In a possible implementation of the first aspect, the method further includes: after receiving a message of consent to share returned by the first target device, marking the state of the first target device as a third state in the sharing interface, where the third state is used to indicate a data transmission status.
[0019] Through the above implementation, when the electronic device receives a message of consent to share returned by any device, it displays the corresponding transmission status on the sharing interface, so that the user feels that the electronic device has started to transmit the shared data to the device, thereby creating an effect of the electronic device performing multi-channel data transmission at the same time (in fact, the electronic device can only transmit data to N devices at most at the same time, and the other devices that need to transmit shared data are not connected to the device at the same time).
[0020] In a possible implementation manner of the first aspect, the third state further displays the progress of data transmission to the first target device, or a corresponding data transmission progress bar surrounds the icon of the first target device.
[0021] In a possible implementation of the first aspect, the sharing interface includes a first area for indicating a user device, a second area for indicating a contact device, and a third area for indicating other devices.
[0022] Through the above implementation, the devices discovered by the electronic device can be displayed in categories in the sharing interface, so that the user can select the device to be shared.
[0023] In a possible implementation manner of the first aspect, the second area includes a name and an icon of the successfully authenticated contact device, and the third area includes at least one of the following:
[0024] The name and icon of non-contact devices, the name and icon of contact devices to be authenticated, and the name and icon of contact devices that failed authentication.
[0025] In a possible implementation of the first aspect, the icons in the second area are contact icons corresponding to respective contact devices, and the icons in the third area are device icons.
[0026] In a possible implementation manner of the first aspect, establishing M physical links with the M target devices respectively includes:
[0027] If M is less than or equal to N, then M physical links are directly established with the M target devices, where N is the number of physical links that the electronic device is allowed to establish simultaneously;
[0028] If M is greater than N, M physical links are established with the M target devices respectively according to a preset physical link scheduling rule, where the physical link scheduling rule indicates the priorities and link preemption rules of multiple devices when establishing physical links.
[0029] Through the above implementation, when the electronic device establishes physical links with multiple devices at the same time, the electronic device can first establish a physical link with a device with a higher priority, thereby allocating the physical link resources of the electronic device more reasonably.
[0030] In a possible implementation manner of the first aspect, the physical link scheduling rule includes:
[0031] The priority of establishing a physical link for a device waiting to send a sharing request, a device waiting to transmit shared data, and a device waiting to perform contact device authentication is reduced in sequence.
[0032] Through the above implementation, the device selected by the user to share can receive the sharing request as quickly as possible, further improving the user experience.
[0033] In a possible implementation manner of the first aspect, the method further includes:
[0034] After sending a sharing request to the first target device, if no message agreeing to share is received within the first time period and the physical link established by the electronic device is equal to N, according to the physical link scheduling rules, other target devices with higher priorities preempt the physical link currently established by the first target device, and the physical link currently established by the first target device is disconnected.
[0035] Through the above implementation, after the electronic device sends a sharing request to any target device, it will not disconnect the physical link with the target device for a period of time. In this way, if a message agreeing to share is received from the target device during this period, the electronic device can continue to use the physical link to transmit shared data to the target device, thereby reducing the number of times the physical link is established and improving the overall performance; if no message agreeing to share is received from the target device during this period, the physical link can be disconnected to release the physical link resources so that other subsequent tasks can use the physical link resources.
[0036] In a possible implementation manner of the first aspect, after receiving a message of consent to share returned by the first target device, the method further includes:
[0037] According to the physical link scheduling rule, a physical link is re-established with the first target device, and the shared data is transmitted to the first target device based on the re-established physical link.
[0038] In a possible implementation manner of the first aspect, the physical link includes a WIFI connection, and the method further includes:
[0039] In the case of failure to establish a Wi-Fi connection with the first target device, a Bluetooth connection is established with the first target device. The Bluetooth connection is used as an escape connection to improve the robustness of the data sharing function of the electronic device.
[0040] In a second aspect, an embodiment of the present application provides a data sharing device, which is applied to an electronic device and includes a display module, a receiving module and a sending module.
[0041] The display module is used to: display a sharing interface in response to a first operation, wherein a plurality of devices are displayed in the sharing interface, and the first operation includes turning on a sharing switch;
[0042] The sending module is used to: in response to the second operation, respectively establish M physical links with the M target devices, and the display module is further used to mark the M target devices as a first state in the sharing interface, wherein the second operation represents selecting M target devices from a plurality of devices, M is greater than or equal to 2, and the first state is used to represent that the electronic device is establishing a connection with the corresponding target device;
[0043] The sending module is further used to: after successfully establishing a physical link with a first target device among the M target devices, send a sharing request to the first target device;
[0044] The receiving module is used to receive a message returned by the first target device indicating consent to share, and the sending module is also used to transmit the shared data to the first target device.
[0045] In a possible implementation manner of the second aspect, after successfully establishing a physical link with a first target device among the M target devices, the sending module is further configured to:
[0046] authenticating the first target device through a physical link established with the first target device;
[0047] After the first target device is successfully authenticated, a sharing request is sent to the first target device.
[0048] In a possible implementation manner of the second aspect, after the sending module successfully establishes a physical link with a first target device among the M target devices, the display module is further configured to:
[0049] In the sharing interface, the first target device is marked as a second state, and the second state is used to indicate that the first target device is in an authentication state or a data transmission preparation state.
[0050] In a possible implementation of the second aspect, the display module is also used to: after the receiving module receives a message of consent to share returned by the first target device, mark the status of the first target device as a third status in the sharing interface, and the third status is used to indicate the status of data transmission in progress.
[0051] In a possible implementation manner of the second aspect, the third state further displays the progress of data transmission to the first target device, or a corresponding data transmission progress bar surrounds the icon of the first target device.
[0052] In a possible implementation of the second aspect, the sharing interface includes a first area for indicating a user device, a second area for indicating a contact device, and a third area for indicating other devices.
[0053] In a possible implementation of the second aspect, the second area includes a name and an icon of the successfully authenticated contact device, and the third area includes at least one of the following:
[0054] The name and icon of non-contact devices, the name and icon of contact devices to be authenticated, and the name and icon of contact devices that failed authentication.
[0055] In a possible implementation of the second aspect, the icons in the second area are contact icons corresponding to respective contact devices, and the icons in the third area are device icons.
[0056] In a possible implementation manner of the second aspect, the sending module is further specifically configured to:
[0057] If M is less than or equal to N, then M physical links are directly established with the M target devices, where N is the number of physical links that the electronic device is allowed to establish simultaneously;
[0058] If M is greater than N, M physical links are established with the M target devices respectively according to a preset physical link scheduling rule, where the physical link scheduling rule indicates the priorities and link preemption rules of multiple devices when establishing physical links.
[0059] In a possible implementation of the second aspect, the physical link scheduling rule includes:
[0060] The priority of establishing a physical link for a device waiting to send a sharing request, a device waiting to transmit shared data, and a device waiting to perform contact device authentication is reduced in sequence.
[0061] In a possible implementation manner of the second aspect, the sending module is further used to:
[0062] After sending a sharing request to the first target device, if no message agreeing to share is received within the first time period and the physical link established by the electronic device is equal to N, according to the physical link scheduling rules, other target devices with higher priorities preempt the physical link currently established by the first target device, and the physical link currently established by the first target device is disconnected.
[0063] In a possible implementation manner of the second aspect, the sending module is further used to:
[0064] According to the physical link scheduling rule, a physical link is re-established with the first target device, and the shared data is transmitted to the first target device based on the re-established physical link.
[0065] In a possible implementation manner of the second aspect, the physical link includes a WIFI connection, and the sending module is further used to:
[0066] In case that the Wi-Fi connection to the first target device fails, a Bluetooth connection is established with the first target device.
[0067] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a memory and a processor, the memory being used to store a computer program; the processor being used to execute the method described in the first aspect or any one of the implementations of the first aspect when calling the computer program.
[0068] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method described in the first aspect or any one of the embodiments of the first aspect is implemented.
[0069] In a fifth aspect, an embodiment of the present application provides a computer program product. When the computer program product runs on an electronic device, the electronic device executes the method described in the first aspect or any implementation method of the first aspect.
[0070] In a sixth aspect, an embodiment of the present application provides a chip system, including a processor, the processor is coupled to a memory, and the processor executes a computer program stored in the memory to implement the method described in the first aspect or any embodiment of the first aspect. The chip system can be a single chip or a chip module composed of multiple chips.
[0071] It can be understood that the beneficial effects of the second to sixth aspects mentioned above can be found in the relevant description of the first aspect mentioned above, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0072] Figure 1 A flowchart of a data sharing method provided in an embodiment of the present application;
[0073] Figure 2 to Figure 10 A schematic diagram of a sharing interface provided in an embodiment of the present application;
[0074] Fig.11 A schematic diagram of the structure of a data sharing device provided in an embodiment of the present application;
[0075] Fig.12 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0076] The embodiments of the present application are described below in conjunction with the drawings in the embodiments of the present application. The terms used in the implementation method section of the embodiments of the present application are only used to explain the specific embodiments of the present application, and are not intended to limit the present application. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments.
[0077] At present, terminal devices such as smartphones and tablet computers can support users to share pictures, documents and other data with other devices in a wireless manner. For example, users can share pictures, documents and other data on smartphones and other terminals with other devices through Wi-Fi connections.
[0078] When users need to share to multiple devices, one way is one-to-one sharing. That is, after the user's terminal device shares to one device, it will share to the second device, and so on. This method is extremely inefficient, especially when the user wants to share to many devices, the user's waiting time will become long, and the user experience is very poor.
[0079] Another way is one-to-many sharing at the same time. That is, the user's terminal device shares with all the devices that need to be shared at the same time. Although this method can improve sharing efficiency, when there are many devices being shared at the same time, or the files to be shared are large, it will affect the performance of the user's terminal device (that is, the sharing device), making the speed of the user's terminal device transferring files to each shared device slow or even fail. The user experience is poor.
[0080] Therefore, the present application provides a data sharing method, which can establish M physical links with the M target devices respectively in response to the operation of the user selecting M target devices from multiple devices in the sharing interface, so that the user can select multiple devices at the same time for data sharing. At the same time, the electronic device marks all the devices selected by the user in the sharing interface as the first state of establishing a connection, so that when the user selects a large number of devices, for example, more than the maximum number of physical links N allowed to be established simultaneously by the electronic device, the electronic device can also show the user that the requests of all devices selected by the user are being processed (for example, the devices in the queue and the devices being connected are all displayed in the interface as being connected, or the devices in the queue and the devices being connected are displayed in different states on the interface, the former is in the connection establishment queue state, and the latter is in the connection establishment state), so as to create the effect that the electronic device supports the establishment of more physical links at the same time, thereby improving the user experience.
[0081] Wherein, N is an integer greater than 1. N may be a fixed value, such as 6, 8, 10, etc., and N may also be adjusted according to the performance of the electronic device, which is not specifically limited in the embodiment of the present application.
[0082] The electronic device can establish a physical link with the target device through Wi-Fi connection, Bluetooth connection, etc. The embodiments of the present application will be explained exemplarily by taking the example of the electronic device establishing a physical link with the target device through Wi-Fi connection.
[0083] When sharing data, electronic devices can establish Wi-Fi connections with other devices by using a terminal station (STA) to connect to a wireless access point (AP), a peer-to-peer (P2P) interface to connect to other P2P devices, and a high-definition multimedia link (HML) interface to connect to other HML devices.
[0084] For each of the above-mentioned Wi-Fi connection modes, the maximum number of Wi-Fi connections that the electronic device can simultaneously establish through the Wi-Fi connection mode may be a set value. The set value corresponding to each Wi-Fi connection mode may be a fixed value, or may be adjusted according to the performance of the electronic device, the supported Wi-Fi connection mode, etc., which is not specifically limited in the embodiments of the present application. N may be less than or equal to the sum of the set values corresponding to each Wi-Fi connection mode.
[0085] For example, if the maximum number of Wi-Fi connections that can be established simultaneously by the electronic device through the STA connection to the AP is 2; the maximum number of Wi-Fi connections that can be established simultaneously by the electronic device through the P2P interface to other P2P devices is 3; the maximum number of Wi-Fi connections that can be established simultaneously by the electronic device through the HML interface to other HML devices is 3, then N can be 8. In the following embodiments of the present application, the setting value corresponding to the STA connection to the AP is 2, the setting value corresponding to the P2P interface connection to other P2P devices is 3, the setting value corresponding to the HML interface connection to other HML devices is 3, and N is 8 as an example for exemplary description.
[0086] When an electronic device needs to establish a Wi-Fi connection with other devices, the electronic device may first determine the number of Wi-Fi connections currently established. When the number of established Wi-Fi connections is less than N, the electronic device may further determine the number of Wi-Fi connections established by each Wi-Fi connection method. If the number of Wi-Fi connections established by a certain Wi-Fi connection method is less than its set value, the electronic device may establish a Wi-Fi connection with other devices through the Wi-Fi connection method. If there are multiple connection methods with a number of Wi-Fi connections less than its set value, the electronic device may randomly select a connection method (the number of Wi-Fi connections established by this connection method is less than its set value) to establish a Wi-Fi connection with other devices.
[0087] For example, if the number of Wi-Fi connections established by the electronic device is 3, the number of Wi-Fi connections established by connecting STA to AP is 1; the number of Wi-Fi connections established by connecting other P2P devices via P2P interface is 0; the number of Wi-Fi connections established by connecting other HML devices via HML interface is 2. Then the electronic device can use any of the above methods to establish a Wi-Fi connection with other devices.
[0088] In some embodiments, if the number of Wi-Fi connections established by multiple connection methods is less than the set value, the electronic device may also preferentially establish a Wi-Fi connection with other devices by connecting to other HML devices through the HML interface. If the number of Wi-Fi connections established by connecting to other HML devices through the HML interface is equal to the set value, the electronic device may choose to establish a Wi-Fi connection with other devices by connecting to other P2P devices through the P2P interface.
[0089] For example, if the number of Wi-Fi connections established by an electronic device is 3, of which the number of Wi-Fi connections established by connecting STA to AP is 1; the number of Wi-Fi connections established by connecting other P2P devices via the P2P interface is 0; and the number of Wi-Fi connections established by connecting other HML devices via the HML interface is 2. Then the electronic device can preferentially establish a Wi-Fi connection with other devices via the HML interface. If the number of Wi-Fi connections established by an electronic device is 3, of which the number of Wi-Fi connections established by connecting STA to AP is 0; the number of Wi-Fi connections established by connecting other P2P devices via the P2P interface is 0; and the number of Wi-Fi connections established by connecting other HML devices via the HML interface is 3. Then the electronic device can establish a Wi-Fi connection with other devices via the P2P interface.
[0090] In some embodiments, for any other device, when the electronic device fails to establish a Wi-Fi connection with the device through any Wi-Fi connection method, if the number of Wi-Fi connections established by other Wi-Fi connection methods is less than its set value, the electronic device can establish a Wi-Fi connection with the device through other Wi-Fi connection methods. If the number of Wi-Fi connections established by other Wi-Fi connection methods is equal to its set value, the electronic device can wait for the Wi-Fi connections established by other Wi-Fi connection methods to be released, and then establish a Wi-Fi connection with the device through other Wi-Fi connection methods.
[0091] In some embodiments, for any other device, if the electronic device cannot establish a Wi-Fi connection with the device through any Wi-Fi connection method (i.e., the Wi-Fi connection fails), the electronic device can also establish a Bluetooth connection with the device, such as a Bluetooth low energy (BLE) connection, etc., to improve the robustness of the data sharing function of the electronic device.
[0092] When an electronic device establishes a Bluetooth connection with another device, it can first determine the number of Bluetooth connections currently established by the electronic device. If the number of Bluetooth connections is less than M, the electronic device can directly establish a Bluetooth connection with the other device; if the number of Bluetooth connections is equal to M, the electronic device can wait to establish a Bluetooth connection until a Bluetooth connection is released. M is an integer greater than 1. M can be a fixed value, such as 3, 4, 5, etc., and M can also be adjusted according to the performance of the electronic device, which is not specifically limited in the embodiments of the present application.
[0093] The data sharing method provided in the embodiments of the present application can be applied to electronic devices, which may include but are not limited to personal computers (PCs), smart phones, netbooks, tablet computers, PDAs, smart screens, etc. For the sake of ease of explanation, the embodiments of the present application will be described exemplarily using a mobile phone as an electronic device.
[0094] Figure 1 A flow chart of a data sharing method provided in an embodiment of the present application is shown as follows: Figure 1 As shown, the data sharing method provided in the embodiment of the present application may include the following steps:
[0095] S1001. In response to a first operation, the electronic device displays a sharing interface.
[0096] The first operation may be an operation of a user triggering sharing (such as Huawei sharing). The user may trigger sharing by touch (such as clicking, long pressing, etc.), or by voice input, gesture, or remote control, etc., which is not specifically limited in the embodiments of the present application.
[0097] In some embodiments, the first operation may also be an operation by the user to turn on the sharing switch. The user may turn on the sharing switch by touch (such as clicking, long pressing, etc.), or by voice input, gesture, or remote control. The embodiments of the present application do not specifically limit this.
[0098] The naming of user operations in the embodiments of the present application is only an example and should not be understood as limiting the embodiments of the present application. In some embodiments, the same operation may also be named by other names. Similarly, the naming of various functions, interfaces, and interface elements in the embodiments of the present application is only an example and is not intended to limit the present application. In other embodiments, other names may also be used.
[0099] The electronic device may first perform an operation of discovering a device in response to the first operation.
[0100] When discovering a device, the electronic device can obtain information about other devices of the user under the same account (such as device name, device type, etc.), or discover the device by receiving information broadcast by other devices. The information broadcast by each other device can contain the device identifier of the device (such as device serial number, hash identifier, etc.).
[0101] The electronic device can then perform a preliminary screening of each device found.
[0102] Specifically, the electronic device will preliminarily screen other devices under the same account as itself as user devices. For each device that sends a broadcast, the electronic device can use the device ID of the device to match the device IDs corresponding to the contacts in the address book. If a match is found, the device can be preliminarily screened as a contact device; if a match is not found, the device can be preliminarily screened as a non-contact device (that is, the preliminarily screened device is neither a user device nor a contact device).
[0103] The electronic device can then display the information of each device after preliminary screening on the sharing interface.
[0104] For example, Figure 2 As shown, the sharing interface may include a first area (i.e., my device area), a second area (i.e., the contact device area), and a third area (i.e., the other device area). The first area, the second area, and the third area may specifically include information such as the device name and device icon of each device after preliminary screening. Among them, the first area may be used to indicate user devices after preliminary screening of electronic devices, such as device 1 and device 2. The second area may be used to indicate preliminary screened contact devices, such as device 3, device 4, device 5, and device 6. The third area may be used to indicate preliminary screened non-contact devices, such as device 7, device 8, device 9, and device 10.
[0105] The sharing interface shown in the embodiment of this application is only an example and is not intended to limit this application. In some embodiments, the sharing interface displayed by the electronic device may include more or fewer interface elements than shown in the figure to implement more or fewer functions; the position of each interface element can be adjusted as needed; each function can also be implemented using other interface elements or in other user interfaces, and this embodiment does not specifically limit this.
[0106] In some embodiments, after the preliminary screening, the electronic device may further perform device authentication on the preliminary screened contact devices to determine whether the preliminary screened contact devices are authentic contact devices.
[0107] Specifically, for each contact device that is initially screened, the electronic device can first establish a Wi-Fi connection with the contact device and send a request to the contact device to obtain a device identifier. After receiving the device identifier returned by the contact device, the electronic device can use the received device identifier to match the device identifiers corresponding to each contact in the address book. If a match is found, the authentication of the initially screened contact device is successful; if no match is found, the authentication of the initially screened contact device fails.
[0108] When the electronic device establishes a Wi-Fi connection with the preliminarily screened contact device for device authentication, it can first determine the number of Wi-Fi connections currently established. When the number of Wi-Fi connections currently established is less than N, the electronic device can directly establish a Wi-Fi connection with the preliminarily screened contact device (that is, the contact device to be authenticated) to authenticate the contact device; when the number of Wi-Fi connections currently established is equal to N, the electronic device can wait for authentication. During the waiting process, if a Wi-Fi connection is released and there is currently no task with a higher priority waiting to establish a Wi-Fi connection (such as waiting to establish a Wi-Fi connection to send a sharing request, waiting to establish a Wi-Fi connection to transmit shared data, etc.), the electronic device can establish a Wi-Fi connection with the contact device to be authenticated to authenticate the contact device. If there is a task with a higher priority waiting to establish a Wi-Fi connection, the electronic device can continue to wait.
[0109] For a successfully authenticated device, the electronic device may change the device icon of the device in the contact device area to a corresponding contact icon, which may be obtained from the address book of the electronic device. Figure 3 As shown in (a) and (b), after device 3 is successfully authenticated, the device icon displayed by device 3 in the contact device area changes to the corresponding contact icon.
[0110] For a device that fails authentication, the electronic device may delete the device information displayed in the contact device area and display it in other device areas. Figure 4 As shown in (a) and (b) in FIG. 1 , after device 4 fails authentication, the device name and device icon of device 4 displayed in the contact device area change to being displayed in the other device area.
[0111] In some embodiments, if a device fails to authenticate, it indicates that there may be a counterfeit contact device. In this case, the electronic device can prompt the user that the device authentication has failed, allowing the user to decide whether to share data with the device.
[0112] In some embodiments, the contact device area may also only display device information corresponding to devices that have been successfully authenticated. Correspondingly, the other device area may display device information of non-contact devices, device information of contact devices to be authenticated, and device information of contact devices that have failed authentication.
[0113] For example, Figure 5 As shown in (a) and (b) in the figure, if no device authentication is successful, the contact device area does not display device information, and the device information of the preliminarily screened contact devices and the preliminarily screened non-contact devices are all displayed in the other device area. After device 3 is successfully authenticated, the device information of device 3 displayed in the other device area changes to being displayed in the contact device area, and the device icon of device 3 changes to the corresponding contact icon.
[0114] S1002: In response to the second operation, the electronic device establishes M Wi-Fi connections with the M target devices respectively.
[0115] The second operation may be an operation in which the user selects M target devices from multiple devices in the sharing interface for data sharing. For example, the user clicks on the device icon, contact icon, or device name of the target device in the sharing interface. M is greater than or equal to 2.
[0116] In some embodiments, the electronic device may directly establish M Wi-Fi connections with the M target devices respectively in response to the second operation.
[0117] Since the electronic device has a great impact on the performance of the electronic device when a large number of Wi-Fi connections are established at the same time, in some embodiments, the electronic device may also respond to the second operation by first comparing M with N (i.e., the maximum number of Wi-Fi connections that the electronic device allows to be established simultaneously). If M is less than or equal to N, the electronic device may directly establish M Wi-Fi connections with the M target devices respectively; if M is greater than N, the electronic device may first select N target devices from the M target devices, and then establish N Wi-Fi connections with the N target devices respectively, and the remaining MN target devices need to queue up and wait for available Wi-Fi connection resources.
[0118] The electronic device may randomly select N target devices from the M target devices, or may select the N target devices first selected by the user according to the selection order of the user in the sharing interface.
[0119] In some embodiments, the electronic device may also establish a Wi-Fi connection with each target device according to a physical link scheduling rule (used to indicate the priority and link preemption rule of the electronic device when establishing a physical link with multiple devices). This allows the electronic device to establish a Wi-Fi connection with a device with a higher priority first, thereby allocating the Wi-Fi connection resources of the electronic device more reasonably.
[0120] The priorities of multiple devices when establishing a physical link may include: the priority of a device waiting to send a sharing request > the priority of a device waiting to transmit shared data > the priority of a device waiting to perform contact device authentication.
[0121] For example, the electronic device waits to send a sharing request to device A and waits to transmit shared data to device B. If a Wi-Fi connection resource is released, the electronic device preferentially uses the Wi-Fi connection resource to establish a Wi-Fi connection with device A to send a sharing request to device A.
[0122] For another example, the electronic device is waiting to transmit shared data to device B and waiting to authenticate the contact device of device C. If a Wi-Fi connection resource is released, the electronic device preferentially uses the Wi-Fi connection resource to establish a Wi-Fi connection with device B to transmit shared data to device B.
[0123] The link preemption rules for multiple devices when establishing a physical link may include: the physical link after sending a sharing request to any device can be preempted by other devices with higher priority (such as waiting to send a sharing request, waiting to transmit shared data, etc.), and the physical link resources occupied by other lower-priority services (such as the P2P connection established by the database when the connection module records the foreground and background services of the application, etc.) can be preempted by other devices with higher priority (such as waiting to send a sharing request, waiting to transmit shared data, waiting to perform contact device authentication, etc.).
[0124] S1003: In response to the second operation, the electronic device marks M target devices as being in the first state in the sharing interface.
[0125] The first state can be used to indicate that the electronic device is establishing a connection with the corresponding target device. In this way, when the user selects a large number of devices, for example, when the number is greater than the maximum number of Wi-Fi connections N that the electronic device allows to be established simultaneously, the electronic device can also show the user that the requests of all devices selected by the user are being processed (for example, the devices in the queue and the devices being connected are both displayed on the interface as being connected, or the devices in the queue and the devices being connected are displayed in different states on the interface, the former being in the connection establishment queue state and the latter being in the connection establishment state), thereby creating the effect that the electronic device supports the establishment of more Wi-Fi connections at the same time and improving the user experience.
[0126] In some embodiments, the electronic device may mark the device as being in the first state by displaying words such as "establishing connection" or "connecting" below the device name. Figure 6 As shown in (a) and (b) in the figure, the user selects device 3, device 4 and device 5 in the sharing interface to share data, and "Connecting" is displayed under device 3, device 4 and device 5.
[0127] In some embodiments, the electronic device may mark the device as the first state by displaying a refresh icon below the device name. Figure 7 As shown in (a) and (b), the user selects device 3, device 4, device 5 and device 6 in the sharing interface to share data, and a refresh icon is displayed under device 3, device 4, device 5 and device 6.
[0128] S1004: After successfully establishing a first Wi-Fi connection with a first target device among the M target devices, the electronic device sends a sharing request to the first target device.
[0129] The electronic device may establish a first Wi-Fi connection with the first target device by connecting a STA to an AP, connecting a P2P interface to other P2P devices, and connecting an HML interface to other HML devices.
[0130] In the case that the above methods all fail to establish the first Wi-Fi connection with the first target device, the electronic device may also establish a Bluetooth connection with the first target device, and send a sharing request to the first target device via the Bluetooth connection.
[0131] In some embodiments, if the first target device is a contact device that has been preliminarily screened and device authentication has not yet been performed, the electronic device may further perform device authentication on the first target device after establishing a connection with the first target device.
[0132] In some embodiments, after successfully establishing a Wi-Fi connection with the first target device, the electronic device may also mark the first target device as a second state in the sharing interface. The second state may include an authenticating state or a data transmission preparation state.
[0133] The electronic device can mark the device as the second state by displaying words such as "authenticating", "sharing request sending" or "data transmission preparing" below the device name. For example, after the electronic device successfully establishes a Wi-Fi connection with device 4, if device 4 is a contact device that has been initially screened and has not yet been authenticated, the electronic device will first authenticate device 4 and then, if Figure 8 As shown in (a) of FIG. 4 , the words “authenticating” are displayed below the name of device 4. After successful authentication, a sharing request can be sent to device 4. Figure 8 As shown in (b) in the figure, the icon of device 4 is replaced with the corresponding contact icon, and the words "sharing request sending" are displayed below the name of device 4.
[0134] By marking M target devices as the first state or the second state, the state of each device selected by the user to share data can be dynamically adjusted, thereby reflecting the difference in the interaction process between the electronic device and each device selected by the user, making the multi-way interaction more realistic. For example, the user selects device 1 to device 10 for data sharing, where the electronic device simultaneously establishes Wi-Fi connections with devices 1 to 8 respectively, and devices 9 and 10 queue up to establish Wi-Fi connections. Then the sharing interface can be as follows Fig. 9 As shown, devices 1 to 8 display a first state, wherein devices 1 to 4 and devices 7 and 8 display that a sharing request is being sent, and devices 5 and 6 display that an authentication is being performed. Devices 9 and 10 display a second state, namely, connecting.
[0135] In some embodiments, after sending a sharing request to the first target device, if a message agreeing to share is not received from the first target device within a first time period (such as 3 seconds, 5 seconds, etc.), the electronic device can disconnect the first Wi-Fi connection with the first target device. In this way, if a message agreeing to share is received from the target device within the first time, the electronic device can continue to use the Wi-Fi connection to transmit shared data to the first target device, thereby reducing the number of times the Wi-Fi connection is established and improving overall performance; if a message agreeing to share is not received from the first target device within the first time, the Wi-Fi connection can be disconnected to release the Wi-Fi connection resources so that other subsequent tasks can use the Wi-Fi connection resources.
[0136] In some embodiments, after sending a sharing request to the first target device, if the electronic device receives a message from the first target device indicating rejection of sharing, the electronic device may disconnect the first Wi-Fi connection with the first target device.
[0137] In some embodiments, after the electronic device sends a sharing request to the first target device, before the first target device returns a message agreeing to share to the electronic device, if the Wi-Fi connection established by the electronic device is equal to N, and there is a device waiting to establish a Wi-Fi connection, the electronic device can disconnect the Wi-Fi connection with the first target device. In this way, the device waiting to establish a Wi-Fi connection can use the Wi-Fi connection resources between the electronic device and the first target device, so that the Wi-Fi connection resources of the electronic device can be more reasonably allocated.
[0138] In some embodiments, the electronic device may also release some Wi-Fi connection resources occupied by other lower-priority services (such as the P2P connection established by the database when the connection module records the foreground and background services of the application, etc.), and seize the released Wi-Fi connection resources, establish a first Wi-Fi connection with the first target device, and send a sharing request to the first target device.
[0139] S1005: The first target device receives the sharing request and displays the sharing request.
[0140] The sharing request displayed by the first target device may include the name of the electronic device, information such as the name and type of data that the electronic device wants to share with the first target device, and accept and reject buttons.
[0141] S1006: In response to the operation of agreeing to share, the first target device sends a message of agreeing to share to the electronic device.
[0142] The operation of agreeing to share may be an operation in which the user clicks a receive button, etc.
[0143] S1007: The electronic device receives a message of consent to share sent by the first target device, and displays the progress of transmitting data to the first target device in the sharing interface.
[0144] After receiving a message from any device agreeing to share, the electronic device can mark the status of the device as the third status in the sharing interface, and the third status can be used to indicate the data transmission status when the electronic device transmits shared data to the device. The third status can include waiting for transmission, transmitting, etc.
[0145] In some embodiments, the electronic device can also display the corresponding transmission progress on the sharing interface, making the user feel that the electronic device has started transmitting the shared data to the device, thereby creating the effect that the electronic device is simultaneously transmitting multiple data channels (in fact, the electronic device can only transmit data to N devices at most at the same time, and the remaining devices that need to transmit shared data need to wait in line).
[0146] For example, for a device waiting for transmission, the electronic device can display its corresponding data transmission progress as 0 in the sharing interface, and for a device that is transmitting shared data, the electronic device can display its actual data transmission progress in the sharing interface.
[0147] The transfer progress can be displayed in the form of a percentage number or a progress bar. The progress bar can be located below or above the icon of the first target device (which can be a device icon or a contact icon), or can be displayed as Fig.10 As shown, it surrounds the icon of the first target device.
[0148] In some embodiments, for devices that are waiting in line to transmit shared data, the electronic device may also display a lower transmission progress in the sharing interface, such as 3%, 5%, etc.
[0149] S1008. The electronic device determines whether the first Wi-Fi connection between the electronic device and the first target device is disconnected. If not, execute step S1009; otherwise, execute step S1010.
[0150] S1009: The electronic device transmits shared data to the first target device through the first Wi-Fi connection.
[0151] When the electronic device is transmitting the shared data to the first target device, the sharing interface may display the actual progress of transmitting the shared data to the first target device.
[0152] S1010. The electronic device compares the number of established Wi-Fi connections with N. If the number of Wi-Fi connections is less than N, step S1011 is executed. If the number of Wi-Fi connections is equal to N, step S1012 is executed.
[0153] S1011. The electronic device establishes a second Wi-Fi connection with the first target device, and transmits shared data to the first target device.
[0154] The electronic device may establish a second Wi-Fi connection with the first target device by connecting the STA to the AP, connecting the P2P interface to other P2P devices, and connecting the HML interface to other HML devices.
[0155] In the case that the second Wi-Fi connection to the first target device fails to be established through the above methods, the electronic device may also establish a Bluetooth connection with the first target device, and transmit the shared data to the first target device through the Bluetooth connection.
[0156] S1012, the electronic device waits for the transmission of shared data. During the waiting process, if a Wi-Fi connection is released, it is determined whether there is a request waiting to send a sharing request, if not, step S1013 is executed, otherwise, the waiting continues.
[0157] S1013: The electronic device seizes the released Wi-Fi connection resources, establishes a second Wi-Fi connection with the first target device, and transmits shared data to the first target device.
[0158] While waiting to transmit shared data, if a Wi-Fi connection is released and there is currently no request waiting to be sent for sharing, the electronic device seizes the released Wi-Fi connection resources, establishes a second Wi-Fi connection with the first target device, and transmits shared data to the first target device.
[0159] In some embodiments, while waiting for the transmission of shared data, the electronic device may also release some Wi-Fi connection resources occupied by other lower-priority services, and seize the released Wi-Fi connection resources to establish a second Wi-Fi connection with the first target device to transmit shared data to the first target device.
[0160] S1014: The first target device receives the shared data sent by the electronic device.
[0161] In the data sharing method provided by the embodiment of the present application, the electronic device responds to the operation of the user selecting M target devices from multiple devices in the sharing interface, and respectively establishes M physical links with the M target devices, so that the user can select multiple devices at the same time for data sharing. At the same time, the electronic device marks all the devices selected by the user in the sharing interface as the first state of establishing a connection, so that when the user selects a large number of devices, for example, more than the maximum number of physical links N allowed to be established simultaneously by the electronic device, the electronic device can also show the user that the requests of all the devices selected by the user are being processed (for example, the devices in the queue and the devices being connected are all displayed in the interface as being in the state of establishing a connection, or the devices in the queue and the devices being connected are displayed in different states on the interface, the former is in the connection establishment queue state, and the latter is in the connection establishment state), so as to create the effect that the electronic device supports the establishment of more physical links at the same time, thereby improving the user experience.
[0162] Those skilled in the art will appreciate that the above embodiments are exemplary and are not intended to limit the present application. Where possible, one or more of the above steps may be selectively combined to obtain one or more other embodiments. For example, in some embodiments, only steps S1001 to S1006 and steps S1013 and S1014 may be performed, and in some embodiments, steps S1007 and S1008 may not be performed. In some embodiments, some of the steps in steps S1007 to S1013 may be performed. Those skilled in the art may select and combine any of the above steps as needed, and all steps that do not depart from the essence of the present application shall fall within the scope of protection of the present application.
[0163] Based on the same concept, as an implementation of the above method, an embodiment of the present application provides a data sharing device, and the device embodiment corresponds to the above method embodiment. For ease of reading, the present device embodiment will no longer repeat the details of the above method embodiment one by one, but it should be clear that the device in this embodiment can correspond to all the contents in the above method embodiment.
[0164] Fig.11 A schematic diagram of the structure of a data sharing device provided in an embodiment of the present application is shown in FIG. Fig.11 As shown, the data sharing device provided in this embodiment may include a display module 210 , a receiving module 220 and a sending module 230 .
[0165] The display module 210 is used to: display a sharing interface in response to a first operation, wherein a plurality of devices are displayed in the sharing interface, and the first operation includes turning on a sharing switch;
[0166] The sending module 230 is used to: in response to the second operation, respectively establish M physical links with the M target devices, and the display module 210 is further used to mark the M target devices as a first state in the sharing interface, wherein the second operation represents selecting M target devices from a plurality of devices, M is greater than or equal to 2, and the first state indicates that the electronic device is establishing a connection with the corresponding target device;
[0167] The sending module 230 is further used to: after successfully establishing a physical link with a first target device among the M target devices, send a sharing request to the first target device;
[0168] The receiving module 220 is used to receive a message returned by the first target device indicating consent to share, and the sending module is further used to transmit the shared data to the first target device.
[0169] As an optional implementation manner, after successfully establishing a physical link with a first target device among the M target devices, the sending module 230 is further configured to:
[0170] authenticating the first target device through a physical link established with the first target device;
[0171] After the first target device is successfully authenticated, a sharing request is sent to the first target device.
[0172] As an optional implementation manner, after the sending module 230 successfully establishes a physical link with the first target device among the M target devices, the display module 210 is further configured to:
[0173] In the sharing interface, the first target device is marked as a second state, and the second state is used to indicate that the first target device is in an authentication state or a data transmission preparation state.
[0174] As an optional implementation, the display module 210 is also used to: after the sending module 230 receives a message of consent to share returned by the first target device, mark the status of the first target device as a third status in the sharing interface, and the third status is used to indicate the status of data transmission.
[0175] As an optional implementation, the third state further displays the progress of data transmission to the first target device, or a corresponding data transmission progress bar surrounds the icon of the first target device.
[0176] As an optional implementation, the sharing interface includes a first area for indicating a user device, a second area for indicating a contact device, and a third area for indicating other devices.
[0177] As an optional implementation, the second area includes the name and icon of the contact device that has been successfully authenticated, and the third area includes at least one of the following:
[0178] The name and icon of non-contact devices, the name and icon of contact devices to be authenticated, and the name and icon of contact devices that failed authentication.
[0179] As an optional implementation, the icons in the second area are contact icons corresponding to the respective contact devices, and the icons in the third area are device icons.
[0180] As an optional implementation manner, the sending module 230 is further specifically configured to:
[0181] If M is less than or equal to N, then M physical links are directly established with the M target devices, where N is the number of physical links that the electronic device is allowed to establish simultaneously;
[0182] If M is greater than N, M physical links are established with the M target devices respectively according to a preset physical link scheduling rule, where the physical link scheduling rule indicates the priorities and link preemption rules of multiple devices when establishing physical links.
[0183] As an optional implementation manner, the physical link scheduling rule includes:
[0184] The priority of establishing a physical link for a device waiting to send a sharing request, a device waiting to transmit shared data, and a device waiting to perform contact device authentication is reduced in sequence.
[0185] As an optional implementation manner, the sending module 230 is further configured to:
[0186] After sending a sharing request to the first target device, if no message agreeing to share is received within the first time period and the physical link established by the electronic device is equal to N, according to the physical link scheduling rules, other target devices with higher priorities preempt the physical link currently established by the first target device, and the physical link currently established by the first target device is disconnected.
[0187] As an optional implementation manner, the sending module 230 is further configured to:
[0188] According to the physical link scheduling rule, a physical link is re-established with the first target device, and the shared data is transmitted to the first target device based on the re-established physical link.
[0189] As an optional implementation manner, the physical link includes a WIFI connection, and the sending module 230 is further used for:
[0190] In case that the Wi-Fi connection to the first target device fails, a Bluetooth connection is established with the first target device.
[0191] The data sharing device provided in this embodiment can execute the above method embodiment, and its implementation principle and technical effect are similar, which will not be repeated here.
[0192] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.
[0193] Based on the same concept, the present application also provides an electronic device, see Fig.12 , Fig.12 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. Fig.12 As shown, the electronic device provided in the embodiment of the present application may include: a memory 310 and a processor 320, the memory 310 is used to store computer programs; the processor 320 is used to implement the method described in the above method embodiment when calling the computer program.
[0194] The electronic device provided in this embodiment can execute the above method embodiment, and its implementation principle and technical effect are similar, which will not be repeated here.
[0195] The embodiment of the present application also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the method described in the above method embodiment is implemented.
[0196] The embodiment of the present application also provides a computer program product. When the computer program product is run on an electronic device, the electronic device implements the method described in the above method embodiment when executing the computer program product.
[0197] The present application also provides a chip system, including a processor, the processor is coupled to a memory, and the processor executes a computer program stored in the memory to implement the method described in the above method embodiment. The chip system can be a single chip or a chip module composed of multiple chips.
[0198] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium or transmitted through the computer-readable storage medium. The computer instructions may be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium (e.g., a floppy disk, a hard disk or a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid state disk (SSD)), etc.
[0199] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by computer programs to instruct related hardware, and the programs can be stored in computer-readable storage media. When the programs are executed, they can include the processes of the above-mentioned method embodiments. The aforementioned storage media can include: ROM or random access memory RAM, magnetic disk or optical disk and other media that can store program codes.
[0200] The naming or numbering of the steps in this application does not mean that the steps in the method flow must be executed in the time / logical sequence indicated by the naming or numbering. The named or numbered process steps can change the execution order according to the technical purpose to be achieved, as long as the same or similar technical effects can be achieved.
[0201] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0202] In the embodiments provided in the present application, it should be understood that the disclosed devices / equipment and methods can be implemented in other ways. For example, the device / equipment embodiments described above are merely schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0203] It should be understood that in the description of the present application specification and the appended claims, the terms "include", "comprises", "have" and any variations thereof are intended to cover non-exclusive inclusions and mean "including but not limited to", unless otherwise specifically emphasized. For example, a process, method, system, product or device that includes a series of steps or modules is not necessarily limited to those steps or modules that are clearly listed, but may include other steps or modules that are not clearly listed or inherent to these processes, methods, products or devices.
[0204] Furthermore, in the description of this application, unless otherwise specified, "plurality" means two or more than two. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, or c can mean: a, b, c, ab, ac, bc, or abc, where a, b, and c can be single or multiple.
[0205] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.
[0206] In addition, in the description of the present specification and the appended claims, the terms "first", "second", etc. are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence, nor can they be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. It should be understood that the numbers used in this way can be interchanged where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein; the features defined as "first" or "second" may explicitly or implicitly include at least one of the features.
[0207] In the embodiments of the present specification, the words "exemplarily" or "for example" are used to indicate examples, illustrations or explanations. Any embodiment or design described as "exemplarily" or "for example" in the embodiments of the present specification should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplarily" or "for example" is intended to present related concepts in a specific way.
[0208] References to "one embodiment" or "some embodiments" etc. described in the specification of the present application mean that one or more embodiments of the specification of the present application include a specific feature, structure or characteristic described in conjunction with the embodiment. Therefore, the phrases "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. appearing in different places in the specification of the present application do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways.
[0209] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.
Claims
1. A method for sharing data between electronic devices, characterized in that: include: In response to a first operation, displaying a sharing interface, wherein a plurality of discovered target devices are displayed in the sharing interface, wherein the first operation includes an operation of triggering sharing by a user; In response to a second operation, establishing physical links with M target devices respectively, wherein the second operation represents selecting the M target devices from the multiple devices, and M is greater than or equal to 2; According to the communication link establishment status and / or device authentication status and / or data transmission status with the first target device among the M target devices, the sharing status of the first target device is marked on the sharing interface, and the sharing status includes any of the following states: a first state indicating that the electronic device is establishing a connection with the corresponding target device, a second state indicating that the first target device is being authenticated, or a third state indicating the progress of data transmission of the first target device, or a fourth state indicating that the first target device is in a data transmission preparation state.
2. The method according to claim 1, characterized in that The third state is displayed by a corresponding data transmission progress bar surrounding the outer periphery of the icon of the first target device.
3. The method according to any one of claims 1 or 2, characterized in that: The sharing interface includes at least two areas, each area displays a different device type and / or user identity; the method further includes: According to the device authentication status with the first target device among the M target devices, the status of the devices included in the different areas of the sharing interface is refreshed.
4. The method according to claim 3, characterized in that The sharing interface includes a first area for indicating a user device, a second area for indicating a contact device, and a third area for indicating other devices.
5. The method according to claim 4, characterized in that The second area includes a name and an icon of the successfully authenticated contact device, and the third area includes at least one of the following: The name and icon of non-contact devices, the name and icon of contact devices to be authenticated, and the name and icon of contact devices that failed authentication.
6. The method according to claim 4 or 5, characterized in that: The icons in the second area are contact icons corresponding to the respective contact devices, and the icons in the third area are device icons.
7. The method according to claim 1, characterized in that The establishing of physical links with the M target devices respectively includes: If M is less than or equal to N, then M physical links are directly established with the M target devices, where N is the number of physical links that the electronic device is allowed to establish simultaneously; If M is greater than N, according to the priority and link preemption rules specified in the preset physical link scheduling rules, M physical links are established with the M target devices respectively in such a way that the target device with a higher priority preempts the link resources of the device with a lower priority.
8. The method according to claim 7, characterized in that The physical link scheduling rules include: The priority of establishing a physical link for a device waiting to send a sharing request, a device waiting to transmit shared data, and a device waiting to perform contact device authentication is reduced in sequence.
9. An electronic device, characterized in that: include: A memory and a processor, wherein the memory is used to store a computer program; and the processor is used to execute the method according to any one of claims 1 to 8 when calling the computer program.
10. A computer program product, characterized in that When the computer program product runs on an electronic device, the electronic device is enabled to execute the method according to any one of claims 1 to 8.
11. A chip system, characterized in that: The chip system includes a processor, which is coupled to a memory, and the processor executes a computer program stored in the memory to implement the method according to any one of claims 1-8.
Citation Information
Patent Citations
Application sharing method, electronic equipment and computer readable storage medium
CN111049980A
Application sharing method, first electronic equipment and computer readable storage medium
CN111309205A
Wireless communication method and terminal equipment
CN114339709A
Data transmission method and system, electronic equipment and storage medium
CN115209393A
Multimedia resource sharing method and electronic equipment
CN115484397A