A communication method, electronic device and system

By broadcasting synchronization information before the short-range wireless communication connection between the smartphone and the smart speaker, parallel execution of Bluetooth connection and media content caching is achieved, solving the problem of large playback latency across smart devices and improving the user experience.

CN114501397BActive Publication Date: 2026-01-27HUAWEI TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202011176711.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-10-28
Publication Date
2026-01-27
Estimated Expiration
2040-10-28

AI Technical Summary

Technical Problem

Existing smartphones and smart speakers suffer from significant latency and poor user experience when switching between devices during media playback, due to the serial execution of Bluetooth connections and media data transmission.

Method used

By broadcasting synchronization information before establishing a near-field wireless communication connection between a smartphone and a smart speaker, Bluetooth connection and media content caching can be performed in parallel. Utilizing Near Field Communication (NFC) and Bluetooth technologies, the smartphone broadcasts the address, playback progress, and speed information of multimedia content, while the smart speaker performs Bluetooth connection and caches multimedia content in parallel, reducing latency.

Benefits of technology

It enables seamless media data switching between smartphones and smart speakers, significantly reducing media playback latency and improving the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114501397B_ABST
    Figure CN114501397B_ABST
Patent Text Reader

Abstract

The application provides a communication method applied to a communication system, the communication system comprising at least a first electronic device and a second electronic device, the method comprising: playing multimedia content by the first electronic device; broadcasting and sending, by the first electronic device, first synchronization information comprising at least a first address, so that the second electronic device receives the first synchronization information; wherein the first address is an acquisition address of the multimedia content; in response to a preset operation, the first electronic device and the second electronic device establish a near field wireless communication connection, and the second electronic device caches the multimedia content according to at least the first address; the first electronic device sends a control instruction to the second electronic device through the near field wireless communication connection; and the second electronic device plays the multimedia content according to the control instruction. The communication method of the application reduces the delay of switching and playing multimedia content between devices, and increases the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communication technology, and in particular to a communication method, electronic device and system. Background Technology

[0002] With the widespread use of smartphones and smart speakers, music played online on smartphones can be transferred to smart speakers for playback, enabling cross-device switching of media playback.

[0003] Current methods for switching media playback across devices using smartphones and smart speakers require establishing a Bluetooth connection between the two devices first, then transmitting streaming media data via Bluetooth. Only after the streaming media data transmission is complete can the smart speaker start playing the media, thus achieving cross-device media playback. This results in a significant delay in cross-device media playback due to the sequential execution of the Bluetooth connection and media data transmission, leading to a poor user experience.

[0004] Application content

[0005] Embodiments of this application provide a communication method, electronic device, and system that solve the problem of large latency when playing multimedia content across devices.

[0006] In a first aspect, this application provides a communication method applied to a communication system, which includes at least a first electronic device and a second electronic device. The method includes: the first electronic device playing multimedia content; the first electronic device broadcasting first synchronization information including at least a first address, where the first address is the acquisition address of the multimedia content, so that the second electronic device receives the first synchronization information; in response to a preset operation, the first electronic device and the second electronic device establish a near-field wireless communication connection, and the second electronic device caches the multimedia content at least according to the first address; the first electronic device sends a control command to the second electronic device through the near-field wireless communication connection; and the second electronic device plays the multimedia content according to the control command.

[0007] In this embodiment of the application, before establishing a short-range wireless communication connection with a second electronic device, the first electronic device broadcasts and sends first synchronization information, which includes at least a first address, so that the second electronic device receives the first synchronization information and achieves parallel execution. The first electronic device establishes a short-range wireless communication connection with the second electronic device, and the second electronic device caches the multimedia content being played by the first electronic device according to the first address, thereby reducing the latency when switching multimedia content between devices and increasing the user experience.

[0008] In one possible implementation, the first synchronization information further includes a first playback progress and a first playback speed of the multimedia content; the second electronic device, in response to a preset operation, caches the multimedia content at least according to the first address, including: the second electronic device caches the multimedia content according to the estimated playback progress and the first address; wherein the estimated playback progress is determined based on the first playback progress, the first playback speed, a first time, and a second time; the first time is the time when the second electronic device receives the first synchronization information, and the second time is the time when the second electronic device detects that the preset operation has occurred. According to this possible implementation, the second electronic device determines the estimated playback progress based on the first playback progress, the first playback speed, the first time, and the second time, and caches the multimedia content starting from the estimated playback progress, increasing the caching speed and further reducing the latency of multimedia content switching playback.

[0009] In one possible implementation, the estimated playback progress is further determined based on a correction time; the second electronic device determines the estimated playback progress based on the sum of the first playback progress and the playback correction progress, wherein the playback correction progress is determined based on the product of the first playback speed and a time difference, the time difference is determined based on the difference between a second correction time and the first time, the second correction time is determined based on the sum of the second time and the correction time, and the correction time is determined based on the time required for the short-range wireless communication connection to be established, and / or by data statistical analysis. According to this possible implementation, the determination condition for the estimated playback progress includes a correction time, making the estimated playback progress more accurate.

[0010] In another possible implementation, the control command further carries second synchronization information, including a second address, a second playback progress, and a second playback speed. The second address, second playback progress, and second playback speed are respectively the acquisition address, playback progress, and playback speed of the multimedia content played by the first electronic device at a third time, where the third time is the time when the near-field wireless communication connection is established. The second electronic device plays the multimedia content according to the control command, including: the second electronic device compares the second address, second playback speed, and second playback progress with the first address, first playback speed, estimated playback progress, and cached progress to obtain a comparison result, and caches or plays the multimedia content according to the comparison result; wherein, the cached progress is the progress of the multimedia content cached by the second electronic device at the third time. According to this possible implementation, the control command carries real playback information, ensuring the accuracy of multimedia content switching playback across devices.

[0011] In another possible implementation, the step of caching or playing the multimedia content according to the comparison result includes: the second electronic device determining whether the comparison result is one or more of the following: the first address and the second address are different, the second playback progress is less than the estimated playback progress and greater than the cached progress; if yes, then the multimedia content is cached according to the second address and the second playback progress; if no, then the multimedia content is played according to the second playback progress and the second playback speed.

[0012] In another possible implementation, the first electronic device includes an NFC module, and the second electronic device is provided with an NFC tag, the NFC tag storing identification information of the second electronic device; the preset operation is a read operation of the first electronic device reading the identification information of the second electronic device stored on the NFC tag via the NFC module; in response to the preset operation, the first electronic device and the second electronic device establish a near-field wireless communication connection, and the second electronic device, in response to the preset operation, caches the multimedia content at least according to the first address, including: the first electronic device reading the identification information of the second electronic device and establishing the near-field wireless communication connection with the second electronic device according to the identification information; the second electronic device detecting the operation of the NFC tag being read, and then caching the multimedia content according to the first address.

[0013] In one example, the identification information includes at least one or more of the following: the MAC address of the second electronic device, the IP address of the second electronic device, and the ID of the second electronic device.

[0014] In another possible implementation, the first electronic device broadcasts first synchronization information, including: the first electronic device broadcasts data packets at a first preset transmission period; if the first address and / or the multimedia content playback parameters change, the first electronic device broadcasts data packets at a second preset transmission period within a first preset time, wherein the second preset transmission period is less than the first preset transmission period, the data packets carry the first synchronization information, and the multimedia content playback parameters include at least the playback speed.

[0015] In another possible implementation, the data packet also carries a hash value of the ID of the electronic device that meets the requirements, the hash value being used by the electronic device receiving the data packet to determine whether to parse the data packet.

[0016] In another possible implementation, the first electronic device broadcasts and sends first synchronization information, which is preceded by: the first electronic device activating near-field discovery function, the second electronic device activating near-field discoverable function, and the first electronic device discovering potential target devices, wherein the potential target devices are: electronic devices that are bound to or have the same account as the first electronic device and / or electronic devices that have established the near-field wireless communication connection with the first electronic device before a second preset time and / or electronic devices with preset profiles.

[0017] In another possible implementation, the first electronic device enables the near-field discovery function, including: the first electronic device determining whether it has established the near-field wireless communication connection with other electronic devices within a third preset time period, and if so, enabling the near-field discovery function.

[0018] In another possible implementation, the near-field wireless communication connection is a BLE connection; the first electronic device establishes a near-field wireless communication connection with the second electronic device in response to a preset operation, including: the first electronic device and the second electronic device establish a BLE connection using a first preset BLE connection parameter and a second preset BLE connection parameter, respectively; wherein, the first preset BLE connection parameter includes at least one or more of a preset BLE scan period and a preset connection scan duty cycle parameter, and the second preset BLE connection parameter includes a preset BLE broadcast transmission period.

[0019] In a first aspect, this application provides a communication method for a first electronic device, the method comprising: the first electronic device playing multimedia content; the first electronic device broadcasting first synchronization information to enable a second electronic device to receive the first synchronization information; wherein the first synchronization information includes at least a first address, the first address being the address for obtaining the multimedia content; the first electronic device establishing a near-field wireless communication connection with the second electronic device in response to a preset operation; the preset operation being used to trigger the establishment of the near-field wireless communication connection between the first electronic device and the second electronic device, and to trigger the second electronic device to cache the multimedia content at least according to the first address; the first electronic device sending a control command to the second electronic device through the near-field wireless communication connection, wherein the control command is used to control the second electronic device to play the multimedia content.

[0020] In one possible implementation, the first synchronization information further includes a first playback progress and a first playback speed of the multimedia content; the first playback progress and the first playback speed are used to determine an estimated playback progress with a first time and a second time, and the estimated playback progress is used by the second electronic device to cache the multimedia content according to the estimated playback progress and the first address; wherein, the first time is the time when the second electronic device receives the first synchronization information, and the second time is the time when the second electronic device detects that the preset operation has occurred.

[0021] In another possible implementation, the estimated playback progress is further determined based on a correction time; the estimated playback progress is determined based on the sum of the first playback progress and the playback correction progress, wherein the playback correction progress is determined based on the product of the first playback speed and the time difference, the time difference is determined based on the difference between the correction second time and the first time, the correction second time is determined based on the sum of the second time and the correction time, and the correction time is determined based on the time required for the short-range wireless communication connection to be established, and / or data statistical analysis.

[0022] In another possible implementation, the control command also carries second synchronization information, which includes a second address, a second playback progress, and a second playback speed. The second address, second playback progress, and second playback speed are respectively the acquisition address, playback progress, and playback speed of the multimedia content played by the first electronic device at a third time. The third time is the time when the near-field wireless communication connection is established. The second synchronization information is used by the second electronic device to compare the second address, second playback speed, and second playback progress with the first address, first playback speed, estimated playback speed, and cached progress to obtain a comparison result, and to cache or play the multimedia content according to the comparison result. The cached progress is the progress of the multimedia content cached by the second electronic device at the third time.

[0023] In another possible implementation, the step of caching or playing the multimedia content based on the comparison result includes: the second electronic device determining whether the comparison result is one or more of the following: the first address and the second address are different, the second playback progress is less than the estimated playback progress, or the second playback progress is greater than the cached progress; if yes, then the multimedia content is cached based on the second address and the second playback progress; if no, then the multimedia content is played based on the second playback progress and the second playback speed.

[0024] In another possible implementation, the first electronic device includes an NFC module, and the second electronic device is provided with an NFC tag, the NFC tag storing identification information of the second electronic device; the first electronic device establishes a near-field wireless communication connection with the second electronic device in response to a preset operation, including: the preset operation being a read operation in which the first electronic device reads the identification information of the second electronic device stored on the NFC tag through the NFC module; the first electronic device reads the identification information of the second electronic device and establishes the near-field wireless communication connection with the second electronic device based on the identification information.

[0025] In another possible implementation, the identification information includes at least one or more of the following: the MAC address of the second electronic device, the IP address of the second electronic device, and the ID of the second electronic device.

[0026] In another possible implementation, the first electronic device broadcasts first synchronization information, including: the first electronic device broadcasts data packets at a first preset transmission period; if the first address and / or the multimedia content playback parameters change, the first electronic device broadcasts data packets at a second preset transmission period within a first preset time, wherein the second preset transmission period is less than the first preset transmission period, the data packets carry the first synchronization information, and the multimedia content playback parameters include at least the playback speed.

[0027] In another possible implementation, the data packet also carries a hash value of the ID of the electronic device that meets the requirements, the hash value being used by the electronic device receiving the data packet to determine whether to parse the data packet.

[0028] In another possible implementation, the first electronic device broadcasts first synchronization information, which is preceded by: the first electronic device activating a near-field discovery function, the first electronic device discovering potential target devices, wherein the potential target devices are: electronic devices that are already bound to or have the same account as the first electronic device and / or electronic devices that have established the near-field wireless communication connection with the first electronic device before a second preset time and / or electronic devices with preset profiles.

[0029] In another possible implementation, the first electronic device enables the near-field discovery function, including: the first electronic device determining whether it has established the near-field wireless communication connection with other electronic devices within a third preset time period, and if so, enabling the near-field discovery function.

[0030] In another possible implementation, the near-field wireless communication connection is a BLE connection; the first electronic device establishes a near-field wireless communication connection with the second electronic device in response to a preset operation, including: the first electronic device establishes a BLE connection with the second electronic device using preset BLE connection parameters; wherein, the preset BLE connection parameters include at least one or more of a preset BLE scan period and a preset connection scan duty cycle parameter.

[0031] Thirdly, this application provides a communication method for a first electronic device, the method comprising: a second electronic device receiving first synchronization information, the first synchronization information being broadcast by a first device, the first synchronization information including at least a first address, the first address being an address for obtaining multimedia content; the multimedia content being content played by the first electronic device; the second electronic device caching the multimedia content at least according to the first address in response to a preset operation; the preset operation being used to trigger the first electronic device and the second electronic device to establish the near-field wireless communication connection, and to trigger the second electronic device to cache the multimedia content at least according to the first address; the second electronic device playing the multimedia content according to a control instruction, the control instruction being sent by the first electronic device to the second electronic device through the near-field wireless communication connection.

[0032] In one possible implementation, the first synchronization information further includes a first playback progress and a first playback speed of the multimedia content; the first playback progress and the first playback speed are used to determine an estimated playback progress with a first time and a second time, and the second electronic device caches the multimedia content according to the estimated playback progress and the first address; wherein, the first time is the time when the second electronic device receives the first synchronization information, and the second time is the time when the second electronic device detects that the preset operation has occurred.

[0033] In another possible implementation, the estimated playback progress is further determined based on a correction time; the estimated playback progress is determined based on the sum of the first playback progress and the playback correction progress, wherein the playback correction progress is determined based on the product of the first playback speed and the time difference, the time difference is determined based on the difference between the correction second time and the first time, the correction second time is determined based on the sum of the second time and the correction time, and the correction time is determined based on the time required for the short-range wireless communication connection to be established, and / or data statistical analysis.

[0034] In another possible implementation, the control command also carries second synchronization information, which includes a second address, a second playback progress, and a second playback speed. The second address, second playback progress, and second playback speed are respectively the acquisition address, playback progress, and playback speed of the multimedia content played by the first electronic device at a third time. The third time is the time when the near-field wireless communication connection is established. The second electronic device compares the second address, second playback speed, and second playback progress with the first address, first playback speed, estimated playback speed, and cached progress to obtain a comparison result, and caches or plays the multimedia content according to the comparison result. The cached progress is the progress of the multimedia content cached by the second electronic device at the third time.

[0035] In another possible implementation, the step of caching or playing the multimedia content based on the comparison result includes: the second electronic device determining whether the comparison result is one or more of the following: the first address and the second address are different, the second playback progress is less than the estimated playback progress, or the second playback progress is greater than the cached progress; if yes, then the multimedia content is cached based on the second address and the second playback progress; if no, then the multimedia content is played based on the second playback progress and the second playback speed.

[0036] In another possible implementation, the first electronic device includes an NFC module, and the second electronic device is provided with an NFC tag, the NFC tag storing identification information of the second electronic device; the second electronic device caches the multimedia content at least according to the first address in response to a preset operation, including: the preset operation being a read operation of the first electronic device reading the identification information of the second electronic device stored on the NFC tag through the NFC module; and the second electronic device caching the multimedia content according to the first address if it detects that the NFC tag has been read.

[0037] In another possible implementation, the identification information includes at least one or more of the following: the MAC address of the second electronic device, the IP address of the second electronic device, and the ID of the second electronic device.

[0038] In another possible implementation, the near-field wireless communication connection is a BLE connection;

[0039] The first electronic device, in response to a preset operation, establishes a near-field wireless communication connection with the second electronic device, including:

[0040] The second electronic device establishes a BLE connection using preset BLE connection parameters; wherein the preset BLE connection parameters include a preset BLE broadcast transmission period.

[0041] Fourthly, this application provides an electronic device, including a memory and a processor, wherein the memory stores executable code, and the processor executes the executable code to implement the method provided in the second or third aspect of this application.

[0042] Fifthly, this application provides a computer-readable storage medium having a computer program stored thereon, which, when executed in a computer, causes the computer to perform the method provided in the second or third aspect of this application.

[0043] In a sixth aspect, this application provides a computer program or computer program product, the computer program or computer program product including instructions that, when executed, implement the method provided in the second or third aspect of this application. Attached Figure Description

[0044] Figure 1 This application provides a schematic diagram of the architecture of a communication system.

[0045] Figure 2 This is a schematic diagram of an application scenario provided by an embodiment of this application;

[0046] Figure 3 Provided for the embodiments of this application Figure 2 A flowchart of the communication method in the scenario shown;

[0047] Figure 4 This is a schematic diagram illustrating that the actual playback progress does not fall within the cached multimedia content segment, as provided in the embodiments of this application.

[0048] Figure 5 A schematic block diagram of an electronic device provided in an embodiment of this application;

[0049] Figure 6 This is a schematic block diagram of an electronic device provided in an embodiment of this application. Detailed Implementation

[0050] The technical solution of this application will be further described in detail below with reference to the accompanying drawings and embodiments.

[0051] This application provides a communication method that can be applied to... Figure 1 In the communication system 100 shown. For example... Figure 1 As shown, the communication system 100 includes N electronic devices, such as electronic device 1, electronic device 2, ..., electronic device N, where N is a positive integer greater than 1. The N electronic devices are connected to each other through a communication network.

[0052] For example, the communication network described above can be a wired communication network or a wireless communication network, and can be a local area network (LAN) or a wide area network (WAN), such as the Internet. The aforementioned communication network can be implemented using any known network communication protocol, which can be various wired or wireless communication protocols, such as Ethernet, Universal Serial Bus (USB), FireWire, Global System for Mobile Communications (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Time-Division Code Division Multiple Access (TD-SCDMA), Long Term Evolution (LTE), Bluetooth, Wireless Fidelity (Wi-Fi), Near Field Communication (NFC), Voice over Internet Protocol (VoIP), communication protocols supporting network slicing architecture, 5G communication protocols, or any other suitable communication protocol.

[0053] Electronic device 1 and electronic device 2 are connected in communication. Electronic device 1 can switch the multimedia content it is playing to electronic device 2 for playback. Electronic device 1 can send control commands to electronic device 2 to control the playback of multimedia content.

[0054] The communication connection between electronic device 1 and electronic device 2 can be established through a short-range communication connection. When electronic device 1 obtains the identification information of electronic device 2, electronic device 1 establishes a communication connection with electronic device 2. Electronic device 2 then plays the multimedia content that it is currently playing or will play, thus realizing cross-device playback of media data with "one-touch switching of playback devices".

[0055] It is understandable that both electronic device 1 and electronic device 2 have near-field communication (NFC) capabilities, such as NFC, Bluetooth, ZigBee, Wi-Fi, UWB, or the Infrared Data Association (IrDA) network. Electronic device 1 can be a smartphone, tablet, personal digital assistant (PDA), wearable electronic device, or other similar device; electronic device 2 can be a smart speaker, smart TV, laptop, in-vehicle playback device, or other device with playback capabilities. Multimedia content can include text content, image content, video content, and audio content.

[0056] The following uses electronic device 1 as a smartphone, electronic device 2 as a smart speaker, and media data as audio data as an example to introduce the cross-device playback method of media data provided in the embodiments of this application.

[0057] Figure 2 This is a schematic diagram of an application scenario provided by an embodiment of this application. The executing entities include a smartphone 31 and a smart speaker 32, both of which have NFC and Bluetooth connectivity. When the smartphone 31 plays the song "Song 1", the smartphone 31 reads the identification information (e.g., MAC address information) of the smart speaker 32 via NFC. Based on this identification information, the smartphone 31 establishes a Bluetooth connection with the smart speaker 32, switching the playback of the song "Song 1" to the smart speaker 32 for playback, thus realizing the "one-touch audio transfer" function.

[0058] Figure 3 Provided for the embodiments of this application Figure 2 A flowchart illustrating the communication method in the scenario shown. Figure 3 As shown, the method includes step S301, whereby the smart speaker enables the near-field device discoverability function, for example, by turning on the Bluetooth connection function and enabling the device discoverability option. This step can be implemented by the user manually turning it on or by the smart speaker automatically turning it on when it is powered on.

[0059] Optionally, step S302, the smartphone detects whether "specific condition 1" is met, and if so, the near-field device discovery function is enabled.

[0060] The aforementioned "specific condition 1" can be that the smartphone is currently playing multimedia content, has a "one-touch audio transfer" configuration file or record locally on the device, and has recently (e.g., within the last 10 days) used the "one-touch audio transfer" function. If the smartphone meets "specific condition 1," the near-field device discovery function will be enabled, for example, by enabling Bluetooth connectivity to scan for nearby connectable devices. This allows the near-field device discovery function to be automatically enabled without user intervention, reducing the frequency of user operations and improving the user experience.

[0061] Of course, step S302 can also be replaced by the smartphone turning on the near-field device discovery function according to the user's instruction. For example, the user manually turns on the smartphone's near-field device discovery function, and the user chooses whether to turn on the smartphone's near-field device discovery function according to their own needs, avoiding the smartphone from turning on the near-field device discovery function unnecessarily and reducing the smartphone's power consumption.

[0062] Step S303: If the smartphone detects a near-field device and the near-field device simultaneously meets "specific condition 2", then step S303a is executed.

[0063] The meaning of "smartphone discovers near-field devices" is: the smartphone scans and discovers nearby devices that can be connected via Bluetooth, that is, it searches for connectable electronic devices within the effective Bluetooth connection range of the Bluetooth smartphone. Simultaneously, to conserve smartphone power, a "specific condition 2" is set in the smartphone; the first synchronization information is broadcast only when specific condition 2 is met. This "specific condition" can be the presence of a potential target device among the near-field devices discovered by the smartphone and / or the smartphone and the potential target device having recently (e.g., within 10 days) used the "One-Touch Audio Transfer" function. The potential target device is a smart speaker with NFC and Bluetooth functions that is already paired with the smartphone, or a smart speaker with NFC and Bluetooth functions that shares the same account (e.g., the same Huawei account) as the smartphone. To avoid the smartphone still sending media data synchronization information to the smart speaker even when the user does not intend to use "One-Touch Audio Transfer," thus increasing smartphone power consumption.

[0064] Understandably, the term "potential target device" refers to a smart speaker that can communicate with a smartphone to achieve "one-touch audio transmission," but has not yet been identified as a target device.

[0065] Step S303a: The smartphone broadcasts multimedia content synchronization information. Specifically, the multimedia content synchronization information (i.e., the first synchronization information) includes at least: a first address, a first playback speed, and a first playback progress. The first address, first playback speed, and first playback progress are respectively the address for obtaining the multimedia content (e.g., the URI (Uniform Resource Identifier) ​​or the URL (Uniform Resource Locator) of the multimedia content data), the playback progress of the multimedia content (e.g., the timestamp of the multimedia content playback), and the playback speed of the multimedia content (e.g., the frame rate of the media content playback).

[0066] For example, a smartphone broadcasts a data packet containing the aforementioned multimedia content synchronization information. The broadcast period is a preset first threshold period for sending the data packet; for example, the first threshold could be 1024ms. Of course, there are various ways for a smartphone to broadcast data packets, such as sending data packets via BLE broadcast or via a local area network broadcast, etc., and this application does not limit the methods.

[0067] In some embodiments, the broadcast data packet also includes a hash value of the ID of the potential target device, restricting only the potential target device to process and parse the broadcast data packet to obtain multimedia content synchronization information, thereby limiting the scope of the broadcast's influence.

[0068] Step S304: The smart speaker updates the local multimedia content information based on the received first synchronization information.

[0069] Specifically, the smart speaker receives broadcast data packets, parses the broadcast data packets to obtain multimedia content synchronization information, and updates the local multimedia content information based on the first synchronization information. When the smart speaker receives a broadcast data packet, it verifies whether the hash value of the broadcast data packet is the same as the hash value of the smart speaker's ID. If so, it parses the broadcast data packet to obtain the first synchronization information and updates the locally stored multimedia content information based on the first synchronization information.

[0070] Step S305: The smartphone determines whether the acquisition address of the multimedia content and / or the playback speed of the multimedia content have been updated. If so, it sends a broadcast data packet containing multimedia content synchronization information within a preset time and at a preset sending cycle.

[0071] Specifically, it determines whether the URI of the multimedia content data (e.g., a smartphone switching songs) and / or the playback speed of the multimedia content (e.g., a smartphone pausing / fast-forwarding / rewinding a song) has changed. If so, it sends a broadcast data packet containing multimedia content synchronization information within a preset time and at a preset sending period. For example, if a smartphone sends a broadcast data packet containing multimedia content synchronization information within 20 seconds at a preset sending period, it can be understood that the preset sending period here is 64ms, which is less than the original broadcast sending period of the smartphone, for example, the original broadcast sending period is 128ms.

[0072] Step S306: The smartphone obtains the identification information of the smart speaker, establishes a Bluetooth connection between the smartphone and the smart speaker, and simultaneously executes the smart speaker to start caching the multimedia content according to the first synchronization information.

[0073] Understandably, smart speakers are equipped with NFC tags (also known as NFC patches). These tags store at least the smart speaker's identification information, which can be its MAC (media access control) address, device name, or IP address—any information that uniquely identifies the smart speaker. The location where the NFC tag is placed on the smart speaker is defined as the NFC sensing area.

[0074] See Figure 2 When a user wants to switch a song playing on their smartphone to play on the smart speaker, they can do so by bringing their smartphone close to / touching the smart speaker's NFC sensing area. When the smartphone and the NFC tag are close enough (e.g., 10cm), the smartphone emits a near-field signal to read the smart speaker's identification information, such as the smart speaker's MAC address, from the NFC tag.

[0075] In other words, by reading the MAC address of the smart speaker, the smartphone can identify the target device as the smart speaker. Then, the smartphone establishes a Bluetooth connection with the smart speaker based on the smart speaker's identification information, and projects the song playing on the smartphone onto the smart speaker for playback.

[0076] It's easy to understand that the smartphone has NFC enabled before it comes close to / touches the smart speaker. This can be done manually by the user or by setting it to automatically enable NFC when playing a song.

[0077] When the smart speaker detects that the NFC tag has been read, it begins to cache media data based on the first synchronization information, enabling parallel execution of Bluetooth connection and data transmission. Compared to the existing method of cross-device playback of media data, which involves first establishing a Bluetooth connection and then transmitting the media data in a serial manner, this greatly reduces the latency of cross-device playback of media data, achieves seamless switching of media data between smartphones and smart speakers, and improves the user experience.

[0078] Specifically, step S306 includes S306.a. The smartphone initiates Bluetooth connection scanning and requests a Bluetooth connection with the smart speaker. S306.b. The smart speaker concurrently initiates Bluetooth connection scanning and establishes a connection with the server storing the multimedia content data based on the URI of the multimedia content data in the first synchronization information. Then, based on the playback progress and playback speed of the multimedia content, it obtains the estimated playback progress when the smartphone and smart speaker establish a Bluetooth connection and switch the multimedia content to the Bluetooth speaker for playback. The smart speaker then starts caching media data from the estimated playback progress node.

[0079] The estimated playback progress can be obtained using the following formula: P estimate =P last +S*(T current -T last update -T delta fix ), where P estimate Indicates the estimated playback progress, P last This indicates the playback progress of the multimedia content in the last received first synchronization information when the smart speaker detects that the NFC tag has been read (i.e., the first playback progress in the first synchronization information received at the first moment), where S represents the playback speed of the multimedia content, and T represents the playback speed of the multimedia content. current T represents the time (i.e., the second time) on the smart speaker when it detects that the NFC tag has been read. last update T represents the time (i.e., the first time) on the smart speaker when it detects that the NFC tag has been read, the time on the smart speaker that last received the first synchronization information. delta fix This represents the time difference correction value, which can be obtained based on the time required for a smartphone and a smart speaker to establish a Bluetooth connection. For example, if the minimum time required for a smartphone and a smart speaker to establish a Bluetooth connection is found to be 400ms, then the correction value T is... delta fix The value is -400ms. Alternatively, this correction value is obtained through extensive statistical analysis of data.

[0080] In another example, in the above formula, T currentThis can be replaced with the time on the smartphone when the smartphone reads the smart speaker's identification information, T. last update It can be replaced with the time on the smartphone that last sent multimedia content synchronization information when the smartphone reads the smart speaker's identification information.

[0081] In another example, when a smart speaker actually caches multimedia content, it can preset the playback progress in advance based on the estimated playback progress before caching. For example, if the preset playback progress is 1 second and the estimated playback progress is 25 seconds, the smart speaker will start caching multimedia content from 24 seconds, making the multimedia content playback more coherent for the user and improving the user experience.

[0082] Of course, to increase Bluetooth connection speed, smart speakers are configured with optimized Bluetooth connection parameters, such as increasing the Bluetooth connection scanning frequency, so that smartphones and smart speakers can establish Bluetooth connections faster.

[0083] Furthermore, when the smartphone obtains the smart speaker's identification information, the smartphone sets optimized Bluetooth connection parameters, such as increasing the connection scan frequency and / or increasing the connection scan duty cycle parameters, to further accelerate the Bluetooth connection speed between the smartphone and the smart speaker.

[0084] It is understandable that "the smartphone reads the Bluetooth speaker's identification information via NFC" is just one way to trigger the establishment of a Bluetooth connection between the smartphone and the smart speaker. Other triggering methods can also be used, such as the smartphone detecting that the button for establishing a Bluetooth connection with the smart speaker has been triggered or detecting a voice command for establishing a Bluetooth connection with the smart speaker.

[0085] Step S307: The smartphone sends control commands to the smart speaker via Bluetooth to control the smart speaker to play media data.

[0086] In some embodiments, step S307 further includes step S307.a: the smartphone stops playing multimedia content. That is, once the smartphone completes the Bluetooth connection with the smart speaker, it stops playing multimedia content and switches the multimedia content to the smart speaker for playback.

[0087] Step S308: The smart speaker starts playing multimedia content according to the estimated playback progress and plays multimedia content according to the control instructions sent by the received smartphone.

[0088] In some embodiments, step S307 further includes the smartphone sending the actual playback progress of the multimedia content to the smart speaker. This actual playback progress is the playback progress at which the smartphone stops playing the multimedia content. In one example, the smartphone stops playing the multimedia content when it completes the Bluetooth connection with the smart speaker. The time on the smart speaker when the smartphone completes the Bluetooth connection with the smart speaker is defined as the third time. Therefore, the actual playback progress is the playback progress of the multimedia content at the third time, and the actual playback progress is the second playback progress.

[0089] Specifically, step S307.1 involves the smart speaker comparing the actual playback progress, the estimated playback progress, and the cached progress (the cached progress is the progress of the multimedia content cached by the smart speaker at the third time) to obtain a comparison result. The result is then determined whether the actual playback progress is less than the estimated playback progress or greater than the cached progress. If so, step S308.2 is executed; otherwise, step S308.1 is executed. S308.1: The smart speaker re-caches the multimedia content according to the actual playback progress. S308.2: The multimedia content is played according to the actual playback progress. Figure 4 As shown, this means the actual playback progress does not fall within the cached multimedia content segment. It's understandable that progress can be represented by timestamps; for example, if a song plays for 45 seconds, the playback progress can be represented as 45 seconds. If it's cached for 50 seconds, the cache progress can be represented as 50 seconds. The actual playback progress not falling within the cached multimedia content segment means the actual playback progress is less than the estimated playback progress or greater than the cached progress. For example, if the estimated playback progress is 25 seconds and the cached progress is 45 seconds, then the cached multimedia content segment is 35 seconds to 55 seconds. If the actual playback progress is less than 35 seconds or greater than 55 seconds, the smart speaker needs to re-cache the multimedia content according to the actual playback progress. Playing media data according to the actual playback progress means starting playback from the actual playback time. For example, if the estimated playback progress is 43 seconds, the smart speaker caches the song at 43 seconds, and the actual playback progress is 45 seconds, then the smart speaker starts playing the song at 45 seconds.

[0090] In some embodiments, step S307 further includes the smartphone sending the actual multimedia content acquisition address (e.g., the URI or URL of the actual multimedia content data) to the smart speaker. Specifically, this includes step S307.2: the smart speaker compares the received actual multimedia content data acquisition address with the multimedia content acquisition address in the last received first synchronization information when the smart speaker detected the NFC tag being read, and caches / plays the multimedia content based on the comparison result. Specifically, if the actual multimedia content acquisition address matches the multimedia content acquisition address in the last received multimedia content synchronization information when the smart speaker detected the NFC tag being read, the multimedia content is played according to the actual playback progress; if the actual multimedia content acquisition address does not match the multimedia content acquisition address in the last received multimedia content synchronization information when the smart speaker detected the NFC tag being read, the multimedia content is cached based on the actual multimedia content acquisition address and the actual playback progress. It should be explained that the actual multimedia content acquisition address is the multimedia content acquisition address when the smartphone and smart speaker successfully establish a Bluetooth connection.

[0091] In some embodiments, step S307 further includes the smartphone sending the playback speed of the actual multimedia content to the smart speaker. Specifically, this includes step S307.3, whereby the smart speaker plays media data according to the playback speed of the actual multimedia content. It can be understood that the playback speed of the actual multimedia content is the playback speed of the multimedia content when the smartphone and smart speaker successfully establish a Bluetooth connection.

[0092] In some embodiments, the actual playback progress of the multimedia content, the actual acquisition address of the multimedia content, and the actual playback speed of the multimedia content (i.e., the second playback progress, the second address, and the second playback speed included in the second synchronization information) can also be sent to the smart speaker in the control command.

[0093] In some embodiments, the method further includes step S309: the smartphone sends multimedia content information to the smart speaker to be played. This includes information such as the playlist, the URI of the multimedia content data in the playlist, and the playback loop mode. Step S310: the smart speaker plays the current multimedia content and caches the upcoming multimedia content based on the received multimedia content information. For example, if the currently playing song is "Song 1," the next song in the playlist is "Song 2," and the loop mode is playlist loop, then the next song to be played is determined to be "Song 2," and the smart speaker plays "Song 1" while caching the next song "Song 2." Step S309 is executed after step S308 or step S308.1.

[0094] In other embodiments, the method further includes step S311: the smartphone caches multimedia content according to the playlist and playback loop mode. Step S312: if the smartphone approaches / touches the smart speaker again to read the smart speaker's identification information, the connection with the smart speaker is disconnected. The smartphone obtains the playback progress of the multimedia content at the time of disconnection and plays the multimedia content according to the playback progress. Step S313: if the smart speaker detects that the smartphone is approaching / touching again and reads the smart speaker's identification information, the connection with the smartphone is disconnected, playback of the multimedia content is stopped, and caching of the multimedia content is stopped. Step S311 is executed after step S308 or step S308.1.

[0095] In other embodiments, the method further includes step S314: the smartphone obtains the real-time playback progress of the multimedia content on the smart speaker. Step S315: if the smartphone approaches / touches the smart speaker again to read the smart speaker's identification information, the connection with the smart speaker is disconnected. The smartphone obtains the real-time playback progress at the time of disconnection, caches the multimedia content, and plays the multimedia content. Step S316: if the smart speaker detects that the smartphone is approaching / touching again and reads the smart speaker's identification information, the connection with the smartphone is disconnected, playback of the multimedia content is stopped, and caching of the multimedia content is stopped. Step S314 is executed after step S308 or step S308.1.

[0096] In other embodiments, step S317 further includes the smartphone approaching / touching the smart speaker again to read the smart speaker's identification information, then disconnecting from the smart speaker, obtaining the playback progress of the multimedia content at the time of disconnection, caching the multimedia content according to the playback progress, and playing the multimedia content. Step S318 involves the smart speaker detecting the smartphone approaching / touching again to read the smart speaker's identification information, then disconnecting from the smart speaker, stopping playback of the multimedia content, and stopping caching of the multimedia content. Step S317 is executed after step S308 or step S308.1.

[0097] In some embodiments, the step S306, "simultaneously executing the smart speaker to start caching multimedia content according to the multimedia content synchronization information," can begin before the smartphone reads the smart speaker's identification information. That is, the smart speaker begins caching multimedia content data according to the multimedia content synchronization information before detecting that the NFC tag has been read. When the smart speaker detects that the NFC tag has been read, it only needs to perform the Bluetooth connection process between the smartphone and the smart speaker. After the Bluetooth connection is complete, the smart speaker obtains the playback progress of the multimedia content and can play the cached multimedia content data according to the playback progress, further reducing latency.

[0098] In some embodiments, after step S305, the method further includes step S305.1: the smartphone and / or smart speaker obtains the network status of its communication network, and determines whether to execute step S306.1 or step S306.2 based on the network status. Step S306.1 involves the smartphone obtaining the smart speaker's identification information, establishing a Bluetooth connection between the smartphone and the smart speaker, and simultaneously executing the smart speaker to begin caching the multimedia content according to the multimedia content synchronization information. Step S306.2 involves executing the caching of multimedia content according to the media data synchronization information, the smartphone obtaining the smart speaker's identification information, and establishing a Bluetooth connection between the smartphone and the smart speaker. After steps S306.1 and S306.2, steps S307 to S308, or steps S307 to S308.1, or steps S307 to S310, or steps S307 to S313, or steps S307 to S316, or steps S307 to S318 are executed.

[0099] Understandably, network status includes network speed. The specific steps for executing either step S306.1 or S306.2 based on network status are: determining whether the network speed exceeds a threshold (e.g., 1 MB / s); if so, executing step S306.1; otherwise, executing step S306.2. That is, when the network status is good, the "smart speaker starts caching multimedia content data according to multimedia content synchronization information" can be performed after the smartphone obtains the smart speaker's identification information. When the network status is poor, this process is performed before the smartphone obtains the smart speaker's identification information, ensuring that the smart speaker's caching of multimedia content data is completed before the Bluetooth connection between the smart speaker and the smartphone is established, thus reducing latency in cross-device media playback.

[0100] In other embodiments, to further reduce the latency of cross-device playback of media data, the aforementioned Bluetooth is BLE (Bluetooth Low Energy), meaning that both smartphones and smart speakers support BLE technology. BLE connection speed is 300ms or faster, while the traditional Bluetooth connection speed is 3s. Using BLE connection achieves faster connection speed and lower power consumption.

[0101] This application provides a computer-readable storage medium having a computer program stored thereon, which, when executed in a computer, causes the computer to perform the communication method described above.

[0102] This application provides a computer program or computer program product, which includes instructions that, when executed, implement the communication method provided above.

[0103] Figure 5 This is a schematic block diagram of an electronic device provided in an embodiment of this application. The electronic device 500 includes a processor 501, a memory 502, an NFC module 503, and a BLE module 504. The memory stores computer execution instructions; when the electronic device 500 is running, the processor 501 executes the computer execution instructions stored in the memory 502 to cause the electronic device 500 to perform... Figure 3 The method steps on the smartphone side include: NFC module 503, used to read NFC tags to obtain content on the NFC tags (e.g., reading an NFC tag on a smart speaker to obtain the smart speaker's identification information); BLE module 504, used to broadcast information (e.g., broadcasting multimedia content synchronization information) and establish a Bluetooth connection with electronic device 2 (e.g., a smart speaker); to send control commands to electronic device 2 via Bluetooth connection.

[0104] In some embodiments, the electronic device 500 further includes a communication bus 505, wherein the processor 501 can be connected to the memory 502, the NFC module 503 and the BLE module 504 via the communication bus 505, thereby enabling the processor 501 to control the NFC module 503 and the BLE module 504 according to the computer execution instructions stored in the memory 502.

[0105] For specific implementation methods of the various components / devices of the electronic device 500 in this application embodiment, please refer to the above description. Figure 3 The implementations of the various methods shown on the smartphone side will not be described in detail here.

[0106] Figure 6 This is a schematic block diagram of an electronic device provided in an embodiment of this application. The electronic device 600 includes a processor 601, a memory 602, an NFC tag 603, and a BLE module 604. The memory stores computer execution instructions; when the electronic device 600 is running, the processor 601 executes the computer execution instructions stored in the memory 602 to cause the electronic device 600 to perform... Figure 3 The method steps shown on the side of the smart speaker are as follows. Among them, the NFC tag 603 is used to store the identification information of the electronic device and can be detected by the electronic device 600 when read; the BLE module 604 is used to establish a BLE connection with the electronic device 1 to receive control commands sent by the electronic device.

[0107] In some embodiments, the electronic device 600 further includes a communication bus 605, wherein the processor 601 can be connected to the memory 602, the NFC tag 603 and the BLE module 604 via the communication bus 605, thereby enabling the processor to control the NFC tag 603 and the BLE module 604 according to the computer execution instructions stored in the memory 602.

[0108] For specific implementation methods of the various components / devices of the electronic device 600 in this application embodiment, please refer to the above description. Figure 3 The implementations of the various methods shown on the smart speaker side will not be described in detail here.

[0109] It is understood that the processor in the embodiments of this application can be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. A general-purpose processor can be a microprocessor or any conventional processor.

[0110] The method steps in the embodiments of this application can be implemented in hardware or by a processor executing software instructions. The software instructions can consist of corresponding software modules, which can be stored in random access memory (RAM), flash memory, read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), registers, hard disks, portable hard disks, CD-ROMs, or any other form of storage medium known in the art. An exemplary storage medium is coupled to the processor, enabling the processor to read information from and write information to the storage medium. Of course, the storage medium can also be a component of the processor. The processor and the storage medium can reside in an ASIC.

[0111] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0112] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein can be implemented in hardware, processor-executed software modules, or a combination of both. The software modules can be located in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disks, removable disks, CD-ROMs, or any other form of storage medium known in the art.

[0113] The specific embodiments described above further illustrate the purpose, technical solution, and beneficial effects of this application. It should be understood that the above description is only a specific embodiment of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.

Claims

1. A communication method, characterized in that, The communication method is applied to a communication system, the communication system including at least a first electronic device and a second electronic device, and the method includes: The first electronic device plays multimedia content; The first electronic device broadcasts first synchronization information so that the second electronic device receives the first synchronization information; wherein, the first synchronization information includes at least a first address, the first address being the address for obtaining the multimedia content; In response to a preset operation, the following operations are performed in parallel: the first electronic device establishes a near-field wireless communication connection with the second electronic device, and the second electronic device caches the multimedia content at least according to the first address; The first electronic device stops playing the multimedia content, and the second electronic device plays the multimedia content. The first electronic device sends control commands to the second electronic device via the near-field wireless communication connection; The second electronic device plays the multimedia content according to the control command; The first electronic device broadcasts first synchronization information, including: The first electronic device broadcasts data packets at a first preset transmission period. If the first address and / or the multimedia content playback parameters change, the first electronic device broadcasts data packets at a second preset transmission period within a first preset time. The second preset transmission period is less than the first preset transmission period. The data packets carry the first synchronization information, and the multimedia content playback parameters include at least the playback speed.

2. The method according to claim 1, characterized in that, The first synchronization information also includes the first playback progress and the first playback speed of the multimedia content; The second electronic device, in response to a preset operation, caches the multimedia content at least according to the first address, including: The second electronic device caches the multimedia content based on the estimated playback progress and the first address; wherein, the estimated playback progress is determined based on the first playback progress, the first playback speed, the first time, and the second time; the first time is the time when the second electronic device receives the first synchronization information, and the second time is the time when the second electronic device detects that the preset operation has occurred.

3. The method according to claim 2, characterized in that, The estimated playback progress is also determined based on the correction time; The second electronic device determines the estimated playback progress based on the sum of the first playback progress and the playback correction progress, wherein the playback correction progress is determined based on the product of the first playback speed and the time difference, the time difference is determined based on the difference between the corrected second time and the first time, the corrected second time is determined based on the sum of the second time and the corrected time, and the corrected time is determined based on the time required for the short-range wireless communication connection to be established, and / or data statistical analysis.

4. The method according to claim 2, characterized in that, The control command also carries second synchronization information, which includes a second address, a second playback progress, and a second playback speed. The second address, the second playback progress, and the second playback speed are respectively the acquisition address, playback progress, and playback speed of the multimedia content played by the first electronic device at the third time. The third time is the time when the near-field wireless communication connection is established. The second electronic device plays the multimedia content according to the control command, including: The second electronic device compares the second address, the second playback speed, the second playback progress with the first address, the first playback speed, the estimated playback progress, and the cache progress to obtain a comparison result, and caches or plays the multimedia content according to the comparison result; wherein, the cache progress is the progress of the multimedia content cached by the second electronic device in the third time.

5. The method according to claim 4, characterized in that, The step of caching or playing the multimedia content based on the comparison result includes: The second electronic device determines whether the comparison result is one or more of the following: The first address and the second address are different, the second playback progress is less than the estimated playback progress, or the second playback progress is greater than the cache progress; If yes, then the multimedia content is cached according to the second address and the second playback progress; otherwise, the multimedia content is played according to the second playback progress and the second playback speed.

6. The method according to claim 1, characterized in that, The first electronic device includes an NFC module, and the second electronic device is provided with an NFC tag, the NFC tag storing the identification information of the second electronic device; The preset operation is a reading operation in which the first electronic device reads the identification information of the second electronic device stored on the NFC tag through the NFC module; In response to a preset operation, the first electronic device establishes a near-field wireless communication connection with the second electronic device, and the second electronic device, in response to the preset operation, caches the multimedia content at least according to the first address, including: The first electronic device reads the identification information of the second electronic device and establishes the short-range wireless communication connection with the second electronic device based on the identification information; If the second electronic device detects that the NFC tag has been read, it caches the multimedia content based on the first address.

7. The method according to claim 6, characterized in that, The identification information includes at least one or more of the following: the MAC address of the second electronic device, the IP address of the second electronic device, and the ID of the second electronic device.

8. The method according to claim 1, characterized in that, The data packet also carries a hash value of the ID of a qualified electronic device, which is used by the electronic device receiving the data packet to determine whether to parse the data packet.

9. The method according to claim 1, characterized in that, The first electronic device broadcasts the first synchronization information, which is preceded by: The first electronic device enables the near-field detection function, and the second electronic device enables the near-field discoverable function. The first electronic device discovers potential target devices, wherein the potential target devices are: electronic devices that are bound to or have the same account as the first electronic device and / or electronic devices that established the near-field wireless communication connection with the first electronic device before a second preset time and / or electronic devices with preset configuration files.

10. The method according to claim 9, characterized in that, The first electronic device enables near-field detection, including: The first electronic device determines whether it has established a near-field wireless communication connection with other electronic devices within a third preset time period. If so, it activates the near-field detection function.

11. The method according to any one of claims 1-10, characterized in that, The short-range wireless communication connection is a BLE connection; The first electronic device, in response to a preset operation, establishes a near-field wireless communication connection with the second electronic device, including: The first electronic device and the second electronic device establish a BLE connection using a first preset BLE connection parameter and a second preset BLE connection parameter, respectively; wherein, the first preset BLE connection parameter includes at least one or more of a preset BLE scan period and a preset connection scan duty cycle parameter, and the second preset BLE connection parameter includes a preset BLE broadcast transmission period.

12. A communication method, characterized in that, The communication method is used in a first electronic device, and the method includes: The first electronic device plays multimedia content; The first electronic device broadcasts first synchronization information so that the second electronic device receives the first synchronization information; wherein, the first synchronization information includes at least a first address, the first address being the address for obtaining the multimedia content; The first electronic device establishes a near-field wireless communication connection with the second electronic device in response to a preset operation; the preset operation is used to trigger the following operations to be performed in parallel: the first electronic device establishes the near-field wireless communication connection with the second electronic device, and the second electronic device caches the multimedia content at least according to the first address, so that the second electronic device can play the multimedia content; The first electronic device stops playing the multimedia content; The first electronic device sends a control command to the second electronic device via the near-field wireless communication connection, wherein the control command is used to control the second electronic device to play the multimedia content; The first electronic device broadcasts first synchronization information, including: The first electronic device broadcasts data packets at a first preset transmission period. If the first address and / or the multimedia content playback parameters change, the first electronic device broadcasts data packets at a second preset transmission period within a first preset time. The second preset transmission period is less than the first preset transmission period. The data packets carry the first synchronization information, and the multimedia content playback parameters include at least the playback speed.

13. The method according to claim 12, characterized in that, The first synchronization information also includes the first playback progress and the first playback speed of the multimedia content; The first playback progress and the first playback speed are used to determine the estimated playback progress with the first time and the second time. The estimated playback progress is used by the second electronic device to cache the multimedia content according to the estimated playback progress and the first address. Wherein, the first time is the time when the second electronic device receives the first synchronization information, and the second time is the time when the second electronic device detects that the preset operation has occurred.

14. The method according to claim 13, characterized in that, The estimated playback progress is also determined based on the correction time; The estimated playback progress is determined based on the sum of the first playback progress and the playback correction progress, wherein the playback correction progress is determined based on the product of the first playback speed and the time difference, the time difference is determined based on the difference between the correction second time and the first time, the correction second time is determined based on the sum of the second time and the correction time, and the correction time is determined based on the time required for the short-range wireless communication connection to be established and / or by data statistical analysis.

15. The method according to claim 13, characterized in that, The control command also carries second synchronization information, which includes a second address, a second playback progress, and a second playback speed. The second address, the second playback progress, and the second playback speed are respectively the acquisition address, playback progress, and playback speed of the multimedia content played by the first electronic device at the third time. The third time is the time when the near-field wireless communication connection is established. The second synchronization information is used by the second electronic device to compare the second address, the second playback speed, the second playback progress and the first address, the first playback speed, the estimated playback and cache progress to obtain a comparison result, and to cache or play the multimedia content according to the comparison result; wherein, the cache progress is the progress of the multimedia content cached by the second electronic device in the third time.

16. The method according to claim 15, characterized in that, The step of caching or playing the multimedia content based on the comparison result includes: The second electronic device determines whether the comparison result is one or more of the following: The first address and the second address are different, the second playback progress is less than the estimated playback progress, or the second playback progress is greater than the cache progress; If yes, then the multimedia content is cached according to the second address and the second playback progress; otherwise, the multimedia content is played according to the second playback progress and the second playback speed.

17. The method according to claim 12, characterized in that, The first electronic device includes an NFC module, and the second electronic device is provided with an NFC tag, the NFC tag storing the identification information of the second electronic device; The first electronic device, in response to a preset operation, establishes a near-field wireless communication connection with the second electronic device, including: The preset operation is a reading operation in which the first electronic device reads the identification information of the second electronic device stored on the NFC tag through the NFC module; The first electronic device reads the identification information of the second electronic device and establishes the short-range wireless communication connection with the second electronic device based on the identification information.

18. The method according to claim 17, characterized in that, The identification information includes at least one or more of the following: the MAC address of the second electronic device, the IP address of the second electronic device, and the ID of the second electronic device.

19. The method according to claim 12, characterized in that, The data packet also carries a hash value of the ID of a qualified electronic device, which is used by the electronic device receiving the data packet to determine whether to parse the data packet.

20. The method according to claim 12, characterized in that, The first electronic device broadcasts the first synchronization information, which is preceded by: The first electronic device activates the near-field detection function and detects potential target devices, wherein the potential target devices are: electronic devices that are already bound to or have the same account as the first electronic device and / or electronic devices that established the near-field wireless communication connection with the first electronic device before a second preset time and / or electronic devices with preset configuration files.

21. The method according to claim 20, characterized in that, The first electronic device enables near-field detection, including: The first electronic device determines whether it has established a near-field wireless communication connection with other electronic devices within a third preset time period. If so, it activates the near-field detection function.

22. The method according to any one of claims 12-21, characterized in that, The short-range wireless communication connection is a BLE connection; The first electronic device, in response to a preset operation, establishes a near-field wireless communication connection with the second electronic device, including: The first electronic device establishes a BLE connection with the second electronic device using preset BLE connection parameters; wherein, the preset BLE connection parameters include at least one or more of the following: a preset BLE scan period and a preset connection scan duty cycle parameter.

23. An electronic device comprising a memory and a processor, characterized in that, The memory stores executable code, and the processor executes the executable code to implement the method according to any one of claims 12-22.

24. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed in a computer, it causes the computer to perform the method described in any one of claims 12-22.

25. A computer program or computer program product, characterized in that, The computer program or computer program product includes instructions that, when executed, implement the method of any one of claims 12-22.

Citation Information

Patent Citations

  • Content playback system, playback device, playback control method and program

    CN101212823A

  • Multimedia sharing method, device and Bluetooth equipment

    CN107071711A

  • Bluetooth voice box synchronous playing method, device and system

    CN111343622A