Data synchronization system, use method and storage medium
By setting up a data synchronization framework and a unified synchronization data protocol inside the electronic device, the problem of data synchronization between multiple electronic devices relying on network and external servers, and a more stable and cross-platform data synchronization function is achieved.
Patent Information
- Application Number
- CN202310949848.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-28
- Publication Date
- 2025-02-14
AI Technical Summary
When synchronizing data between multiple electronic devices, it is necessary to rely on the network and external servers, resulting in poor stability, especially when network conditions are poor or the device does not support networking.
A data synchronization system is provided, by setting a data synchronization framework inside the electronic device, and using a unified synchronous data protocol to perform data encoding and decoding processing, thereby realizing data synchronization between electronic devices.
This solution completes data synchronization processing on the electronic device side, avoids dependence on the network and external servers, improves the stability of data synchronization, and supports cross-platform data synchronization function.
Smart Images

Figure CN119449812A_ABST
Abstract
Description
Technical Field
[0001] Embodiments of the present application relate to the field of communication technology, and more specifically, to a data synchronization system, a use method, and a storage medium. Background Art
[0002] With the development of communication technology, the application scenarios of multiple electronic devices working together are becoming more and more extensive. However, in the process of data synchronization between multiple electronic devices, it is necessary to rely on the network and external servers (cloud servers or manufacturer servers), which has poor stability. Summary of the invention
[0003] The embodiments of the present application provide a data synchronization system, a method for using the system and a storage medium. The following introduces various aspects of the embodiments of the present application.
[0004] In a first aspect, a data synchronization system is provided, which is applied to a first electronic device and is used to interact with a second electronic device outside the first electronic device. The data synchronization system includes: a first business data layer, which is used to generate business data; a first intermediate layer, which includes a first synchronization protocol, and the first intermediate layer is used to encode the business data using the first synchronization protocol to obtain first synchronization data; and a first hardware layer, which is used to send the first synchronization data to the second electronic device.
[0005] In a second aspect, a data synchronization system is provided, which is applied to a second electronic device and is used to interact with a first electronic device outside the second electronic device. The data synchronization system includes: a second hardware layer, used to receive first synchronization data sent by the first electronic device; a second intermediate layer, including a first synchronization protocol, and the second intermediate layer is used to parse and process the first synchronization data using the first synchronization protocol to obtain business data; and a second business data layer, used to obtain the business data from the second intermediate layer.
[0006] In a third aspect, a method for using a data synchronization system is provided, the method being applied to a first electronic device, and the method being used to perform data interaction with a second electronic device outside the first electronic device, the method comprising: generating business data using a first business data layer in the data synchronization system; encoding the business data using a first synchronization protocol of a first intermediate layer in the data synchronization system to obtain first synchronization data; and sending the first synchronization data to the second electronic device using a first hardware layer in the data synchronization system.
[0007] In a fourth aspect, a method for using a data synchronization system is provided, the method being applied to a second electronic device, and the method being used to perform data interaction with a first electronic device outside the second electronic device, the method comprising: utilizing a second hardware layer in the data synchronization system to receive first synchronization data sent by the first electronic device; utilizing a first synchronization protocol of a second intermediate layer in the data synchronization system to parse and process the first synchronization data to obtain business data; and utilizing a second business data layer in the data synchronization system to obtain the business data from the second intermediate layer.
[0008] In a fifth aspect, an electronic device is provided, comprising the data synchronization system as described in the first aspect or the second aspect.
[0009] In a sixth aspect, a computer-readable storage medium is provided, on which an executable code is stored. When the executable code is executed, the method described in the third aspect or the fourth aspect can be implemented.
[0010] The embodiment of the present application provides a data synchronization system, which includes: a first business data layer, which is used to generate business data; a first intermediate layer, which includes a first synchronization protocol, and the first intermediate layer is used to encode the business data using the first synchronization protocol to obtain first synchronization data; a first hardware layer, which is used to send the first synchronization data to a second electronic device. Compared with the traditional solution that relies on the network and external servers to achieve data synchronization, the electronic device of this solution sets a data synchronization framework inside, that is, by setting a unified first synchronization data protocol in the first intermediate layer, the user can complete the data synchronization processing on the electronic device side, which helps to avoid the problem of poor data synchronization stability caused by relying on the network and external servers. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] Figure 1 It is a structural diagram of a data synchronization system provided in one embodiment of the present application.
[0012] Figure 2 It is a structural diagram of a data synchronization system provided in another embodiment of the present application.
[0013] Figure 3 It is a structural diagram of a possible data synchronization system under the Android operating system provided in one embodiment of the present application.
[0014] Figure 4 It is a structural diagram of a possible data synchronization system under the Windows operating system provided in an embodiment of the present application.
[0015] Figure 5 It is a structural diagram of a possible data synchronization system that does not support networking function provided by an embodiment of the present application.
[0016] Figure 6 It is a structural diagram of a possible synchronization service application provided by an embodiment of the present application.
[0017] Figure 7 It is a structural diagram of a possible system service provided by an embodiment of the present application.
[0018] Figure 8 It is a structural diagram of a possible hardware layer provided in an embodiment of the present application.
[0019] Fig. 9 It is a structural diagram of a data synchronization system for performing device discovery provided in one embodiment of the present application.
[0020] Fig.10 It is a flowchart of device discovery using a synchronization system provided in an embodiment of the present application.
[0021] Fig.11 It is a flowchart of a method for using a data synchronization system provided in one embodiment of the present application.
[0022] Fig.12 It is a flowchart of a method for using a data synchronization system provided in another embodiment of the present application.
[0023] Fig.13 It is a schematic diagram of the structure of an electronic device provided in one embodiment of the present application.
[0024] Fig.14 It is a structural schematic diagram of an electronic device provided in another embodiment of the present application. DETAILED DESCRIPTION
[0025] The technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all of the embodiments.
[0026] With the development of communication technology, there are many types of electronic devices and various types of services. The application scenarios of multiple electronic devices working together are becoming more and more extensive. However, the chip platforms or operating systems of different electronic devices may be different. In the process of data synchronization between multiple electronic devices, it is usually necessary to rely on the network and external servers (cloud servers or manufacturer servers). In this case, if the current network is poor or the server is congested (for example, during business peak hours), data synchronization will be unstable. In addition, if an electronic device does not support networking, the cross-platform data synchronization function cannot be realized.
[0027] In order to solve the above problems, an embodiment of the present application provides a data synchronization system, which includes: a first business data layer, which is used to generate business data; a first intermediate layer, which includes a first synchronization protocol, and the first intermediate layer is used to encode the business data using the first synchronization protocol to obtain first synchronization data; a first hardware layer, which is used to send the first synchronization data to the second electronic device. Compared with the traditional solution that relies on the network and external servers to achieve data synchronization, the electronic device of this solution sets a data synchronization framework inside, that is, by setting a unified first synchronization data protocol in the first intermediate layer, the user can complete the data synchronization processing on the electronic device side, which helps to avoid the problem of poor data synchronization stability caused by relying on the network and external servers.
[0028] It should be noted that the data synchronization system in the embodiment of the present application can be applied to the first electronic device. The data synchronization system can be used to interact with the second electronic device outside the first electronic device. The first electronic device and the second electronic device can be electronic devices of the same type or different types.
[0029] It should be noted that the electronic device in the embodiments of the present application may be a mobile phone, a tablet computer (Pad), a laptop computer, a PDA, a mobile internet device (MID), a wearable device, etc., and the present application does not impose specific restrictions on this. In other words, the first electronic device and the second electronic device may be any type of electronic device mentioned above. For example, the first electronic device may be a tablet computer, and the second electronic device may be a mobile phone. For another example, the first electronic device is a mobile phone, and the second electronic device is a wearable device (such as headphones), and the present application does not impose specific restrictions on this.
[0030] It is understandable that the data synchronization system in the embodiment of the present application can also be applied to the second electronic device. In the process of data synchronization between the first electronic device and the second electronic device, one party (such as the first electronic device) can be used to send business data, and the other party (such as the second electronic device) can be used to receive business data. In other words, the data synchronization system in the embodiment of the present application can realize the function of sending and receiving business data (including encoding and parsing functions). For ease of understanding, this application takes the interaction process between the first electronic device (the electronic device that sends business data) and the second electronic device (the electronic device that receives business data) as an example to introduce the data synchronization system.
[0031] It should be noted that the data synchronization system in the first electronic device and the data synchronization system in the second electronic device can be the same type of data synchronization system or different types of data synchronization systems. Regardless of whether the data synchronization systems in the first electronic device and the second electronic device are the same, the data synchronization systems in the first electronic device and the second electronic device include a first synchronization protocol. The first synchronization protocol may refer to a data protocol for encoding (packaging) / parsing (unpackaging) of business data.
[0032] Combined with the following Figure 1 The data synchronization system in the embodiment of the present application is described in detail. The data synchronization system 100 can be applied to a first electronic device. Figure 1 As shown, the data synchronization system 100 includes a first business data layer 120 , a first intermediate layer 140 and a first hardware layer 160 .
[0033] The first business data layer 120 may be used to generate business data. Business data may refer to data that needs to be shared with the second electronic device. The business data may be, for example, context data. As an example, a user edits an email in the first business data layer 120, and the email edit content may be referred to as business data.
[0034] The first intermediate layer 140 includes a first synchronization protocol, and the first intermediate layer 140 can be used to encode the service data using the first synchronization protocol to obtain first synchronization data. In some embodiments, the first synchronization protocol can refer to a Context data transmission protocol.
[0035] It should be understood that the first synchronization protocol can be implemented in a variety of programming languages. Programming languages include but are not limited to any one or more of C, C++, Java, Objective-C, C#, Swift, Python, etc. The programming language can be determined according to the actual requirements and functions of the operating platform.
[0036] The first hardware layer 160 can be used to obtain the first synchronization data from the first intermediate layer 140 and send the first synchronization data to the second electronic device. For example, taking the case where the user edits an email in the first business data layer 120, the first synchronization data can be the business data (edited email content) encoded and processed using the first synchronization protocol. After the first synchronization data is sent to the second electronic device using the first hardware layer 160, data sharing with the second electronic device can be achieved. It should be understood that after the second electronic device obtains the business data (edited email content), it can continue to edit the original edited email content, thereby improving the user experience.
[0037] In some embodiments, the first hardware layer 160 may refer to a hardware layer, and the first hardware layer 160 may include a communication chip, such as a Bluetooth communication chip, a Zigbee communication chip, etc. The first synchronization data may be sent to the second electronic device using the communication chip.
[0038] In some embodiments, the first intermediate layer 140 may include a first business data synchronization service, which may be used to encode business data using a first synchronization protocol to obtain first synchronization data. The first business data synchronization service may refer to a background service process or a background running function resource.
[0039] In some embodiments, the first business data synchronization service is also used to: obtain the status information of the first electronic device; wherein the status information of the first electronic device includes one or more of the following status information: the device status of the first electronic device, the resource status of the first electronic device, and the scenario status of the first electronic device. The device status of the first electronic device may include, for example, the screen-on status and screen-off status of the first electronic device. The resource status of the first electronic device may refer to the device information of the first electronic device, and the device information may include the processor performance of the first electronic device (for example, the application processor is a quad-core processor), the operating system (for example, the Android operating system, the Windows operating system, etc.), the device name information, etc. The scenario status of the first electronic device may include the location status and the moving speed status of the first electronic device. The user's status can be judged according to the scenario status of the first electronic device. For example, according to the moving speed status and the location status of the first electronic device, it can be determined that the user is in an indoor walking state or an outdoor running state. User motion data synchronization is a common scenario. By recording and sharing the user's motion status data, the user can, for example, effectively plan a fitness plan, thereby helping to improve the user experience.
[0040] In some embodiments, the first business data layer 120 may be an application layer, and the first business data layer 120 may include a business data synchronization service application. The business data synchronization service application may be used to send a first instruction to the first business data synchronization service in the first intermediate layer 140 in response to a user triggering a function to obtain the state information of the first electronic device before obtaining the state information of the first electronic device. As an example, the business data synchronization service application may include an acquisition function button for obtaining the state information of the first electronic device, and in response to the acquisition function button being triggered, a first instruction is sent to the first business data synchronization service in the first intermediate layer 140. The first instruction is used to instruct to obtain the state information of the first electronic device.
[0041] In some embodiments, the first service data synchronization service is further used to: configure the subscription service data of the first electronic device before encoding the service data using the first synchronization protocol. The subscription service data of the first electronic device may refer to service data specified by a user.
[0042] In some embodiments, the first business data synchronization service application can be used to send a second instruction to the first business data synchronization service in response to a user triggering a configuration function of the subscription business data of the first electronic device before configuring the subscription business data of the first electronic device; wherein the second instruction is used to indicate the configured subscription business data.
[0043] In some embodiments, the first hardware layer 160 may be a hardware layer, and the first hardware layer 160 may include a first processing chip, a first application chip, and a first wireless communication chip. The first processing chip may refer to a general-purpose processor chip, such as a microcontroller unit (MCU). The first application chip may be, for example, an application processor (AP) or a central processing unit (CPU) of the first electronic device. The first wireless communication chip may be, for example, a short-range communication chip such as a Bluetooth communication chip or a Zifeng communication chip.
[0044] The first processing chip can establish a first data channel with the first service data layer 120; the first application chip can establish a second data channel with the first service data layer 120; the first wireless communication chip is connected to both the first data channel and the second data channel. The first wireless communication chip can be used to send the first synchronization data to the second electronic device.
[0045] In some embodiments, the first business data synchronization service can be used to select a channel for the data channel to transmit the first synchronization data to the first communication chip. For example, the first business data synchronization service can be used to select the second data channel in response to the first synchronization data being subscription business data, and transmit the first synchronization data to the first communication chip through the second data channel; in response to the first synchronization data being non-subscription business data, the first data channel is selected, and the first synchronization data is transmitted to the first communication chip through the first data channel. It can be understood that compared to the first application chip (such as an application chip or a central processing unit chip), the first processing chip (microprocessor chip) can refer to a low-power chip, that is, using the first data channel for data transmission can reduce the power consumption of the electronic device, and the first data channel can also be called a low-power data channel. In the process of using the first data channel for data transmission, the first application chip may not be woken up to save power consumption of the electronic device.
[0046] As an example, in response to the first synchronization data being non-subscription service data, the first synchronization data can be transmitted to the first communication chip through the first data channel, and then the first synchronization data can be sent (e.g., broadcast) to the second electronic device using the first wireless communication chip. Since the first electronic device uses the first data channel (low power consumption channel) to send data (e.g., broadcast), the power consumption is low. Therefore, the first electronic device can achieve continuous or all-weather data transmission (e.g., broadcast). For example, the first electronic device can continuously broadcast the first synchronization data to discover the subscription service data such as device information of the external electronic device subscribed by the first electronic device.
[0047] In some embodiments, if the operating system of the first electronic device is an Android operating system, the first business data layer 120 may be an application layer; the first intermediate layer 140 may be a system framework layer; and the first hardware layer 160 may be a hardware layer. If the operating system of the first electronic device is a Windows operating system, the first business data layer 120 may be an application layer; the first intermediate layer 140 may be a user layer; and the first hardware layer 160 may be a hardware layer. If the first electronic device does not support a networking function, the first business data layer 120 may be a task layer; the first intermediate layer 140 may be a synchronization protocol layer; and the first hardware layer 160 may be a hardware layer. Among them, the task layer may be called a task layer, and the first electronic device may generate business data at the task layer.
[0048] It should be noted that the first business data synchronization service has different names in different operating systems, but its functions are similar. For example, when the operating system of the first electronic device is an Android operating system, the first business data synchronization service can be called a system service or a system service process; when the operating system of the first electronic device is a Windows operating system, the first business data synchronization service can be called a dynamic link library (DLL); when the first electronic device does not support networking functions or does not have an operating system, the first business data synchronization service can be called a shared function library or a shared resource library.
[0049] The above describes the data synchronization system in detail from the perspective of using the first electronic device to send data. Figure 2 The data synchronization system of the present application is described from the perspective of using the second electronic device to receive data. It should be understood that the data synchronization systems in the first electronic device and the second electronic device are corresponding, so the parts not described in detail can refer to the previous embodiment of the data synchronization system in the first electronic device.
[0050] Figure 2Another data synchronization system proposed in the embodiment of the present application. The data synchronization system can be applied to a second electronic device, and the data synchronization system can be used to interact with a first electronic device outside the second electronic device. Figure 2 As shown, the data synchronization system 200 includes a second business data layer 220 , a second intermediate layer 240 and a second hardware layer 260 .
[0051] It can be understood that the data synchronization system 200 may be the same as or different from the data synchronization system 100 mentioned above, but the functions of the synchronization system 200 and the data synchronization system 100 are similar. The synchronization system 200 and the data synchronization system 100 can both send, receive and process business data. The data synchronization system 200 is mainly described from the perspective of receiving business data.
[0052] The second hardware layer 260 can be used to receive the first synchronization data sent by the first electronic device. As an example, the first synchronization data can be the edited part of the email content sent by the user using the first electronic device. When the second electronic device receives the synchronization data, it can realize data sharing with the first electronic device. It should be understood that after the second electronic device obtains the business data (edited email content), it can continue to edit the original edited email content, thereby improving the user experience.
[0053] In some embodiments, the first synchronization data may include status information of the first electronic device, and the status information of the first electronic device may include one or more of the following status information: device status of the first electronic device, resource status of the first electronic device, and scenario status of the first electronic device. For details, please refer to the description of the status information of the first electronic device in the previous text, which will not be repeated here.
[0054] In some embodiments, the second hardware layer 260 may refer to a hardware layer, and the second hardware layer 260 may include a communication chip, such as a Bluetooth communication chip, a Zifeng communication chip, etc. The communication chip may be used to communicate with the first electronic device and to receive the first synchronization data sent by the first electronic device.
[0055] The second intermediate layer 240 includes a first synchronization protocol, and the second intermediate layer 240 can be used to parse and process the first synchronization data using the first synchronization protocol to obtain business data.
[0056] The second business data layer 220 can be used to obtain the parsed business data from the second intermediate layer 240. The business data can refer to the shared data obtained from the first electronic device. The business data can be, for example, context data. As an example, the business data can refer to the email content data edited by the user on the first electronic device.
[0057] In some embodiments, the second intermediate layer 240 may include a second business data synchronization service, and the second business data synchronization service in the second intermediate layer 240 may be used to parse and process the first synchronization data using the first synchronization protocol to obtain business data. The second business data synchronization service may refer to a background service process or a background running function resource, etc. The second business data synchronization service is similar to the first business data synchronization service. For details, please refer to the description of the first business data synchronization service in the previous text, which will not be repeated here.
[0058] In some embodiments, the second hardware layer 260 may include: a second processing chip, a second application chip, and a second wireless communication chip. The second processing chip may be used to establish a third data channel with the second business data layer; the second application chip may be used to establish a fourth data channel with the second business data layer; the second wireless communication chip is connected to both the third data channel and the fourth data channel, and the second wireless communication chip may be used to transmit the first synchronization data to the second intermediate layer 240 through the third data channel or the fourth data channel.
[0059] In some embodiments, the second processing chip may be a general-purpose processor chip, such as a microcontroller unit MCU. The second application chip may be, for example, an application processor AP or a central processing unit CPU of the second electronic device. The second wireless communication chip may be, for example, a short-range communication chip such as a Bluetooth communication chip or a Zifeng communication chip.
[0060] In some embodiments, the second business data synchronization service may be used to select a data channel to receive the first synchronization data. For example, the second business data synchronization service may be used to: in response to the first synchronization data being the subscription business data of the second electronic device and the second application chip being in an awake state, receive the first synchronization data through a fourth data channel; in response to the first synchronization data being the non-subscription business data of the second electronic device, receive the first synchronization data through a third data channel. The wake-up signaling may be, for example, an interrupt signaling.
[0061] In some embodiments, the second service data synchronization service may be used to configure the subscription service data of the second electronic device before receiving the first synchronization data sent by the first electronic device.
[0062] In some embodiments, the second processing chip may include a first synchronization protocol. After acquiring the first synchronization data, the second processing chip may be used to parse and process the first synchronization data using the first synchronization protocol to obtain corresponding business data. Then, the second processing chip may determine whether the business data is the subscription business data of the second electronic device. If the first synchronization data is the subscription business data of the second electronic device, the second application chip is awakened to quickly use or transmit the business data, otherwise, the second wireless communication chip is controlled to transmit the business data to the second intermediate layer 240 through the third data channel.
[0063] In some embodiments, after acquiring the corresponding business data, the second processing chip can store the business data so that it can be quickly queried when the business needs it. For example, in the process of device discovery and connection, the second processing chip can be queried first to see if there is device information that meets the requirements. If the second processing chip has stored the device information that meets the requirements, the device can be directly connected, which will greatly shorten the time of device discovery and improve the efficiency of device connection.
[0064] In some embodiments, the second application chip may include a first synchronization protocol. When the second application chip is awakened, it can obtain first synchronization data from the second wireless communication chip, and parse and process the first synchronization data using the first synchronization protocol to obtain corresponding business data, and transmit the business data to the second intermediate layer 240 using a fourth data channel.
[0065] It can be understood that by setting the first synchronization protocol in the second processing chip or the second application chip, the first synchronization data can be processed by the second processing chip or the second application chip, and then the processed data can be transmitted to the second business data layer through the data channel without the need for processing by the second intermediate layer 240, which can effectively alleviate the processing pressure of the second intermediate layer 240, especially when the business data of the second intermediate layer 240 is congested.
[0066] In some embodiments, after the second processing chip obtains the first synchronization data, the first synchronization data can be transmitted to the second business data synchronization service of the second intermediate layer 240 through the third data channel, and the second business data synchronization service uses the first synchronization protocol to parse and process the first synchronization data to obtain business data. The second business data synchronization service is also used to determine whether the business data is subscribed business data of the second electronic device. If the first synchronization data is subscribed business data of the second electronic device, the fourth data channel is selected to receive the first synchronization data; if the first synchronization data is non-subscribed business data of the second electronic device, the third data channel is selected to receive the first synchronization data.
[0067] In some embodiments, if the operating system of the second electronic device is an Android operating system, the second service data layer 220 may be an application layer; the second intermediate layer 240 may be a system framework layer; and the second hardware layer 260 may be a hardware layer. If the operating system of the second electronic device is a Windows operating system, the second service data layer 220 may be an application layer; the second intermediate layer 240 may be a user layer; and the second hardware layer 260 may be a hardware layer. If the second electronic device does not support networking, the second service data layer 220 may be a task layer; the second intermediate layer 240 may be a synchronization protocol layer; and the second hardware layer 260 may be a hardware layer. Among them, the task layer may be called a task layer, and the first electronic device may generate service data at the task layer.
[0068] It is understandable that, compared with the second application chip (such as an application chip or a central processing unit chip), the second processing chip (such as a microprocessor chip) can be a low-power chip, that is, using the third data channel for data transmission can reduce the power consumption of the electronic device, and the third data channel can also be called a low-power data channel. In the process of using the third data channel for data transmission, the second application chip may not be awakened to save power consumption of the electronic device.
[0069] In some embodiments, the first data channel and the third data channel can be low-power data channels, for example, Bluetooth low energy (BLE) data channels, and the second data channel and the fourth data channel can be regular data channels, for example, traditional Bluetooth data channels, Bluetooth low energy data channels, or Wi-Fi data transmission channels.
[0070] In order to deepen the understanding of the data synchronization system in the embodiment of the present application, Figure 3-Figure 10 The data synchronization system in the embodiment of the present application is described in detail by way of example. It should be understood that Figure 3-Figure 10 The data synchronization system in the embodiment can be applied to the first electronic device or the second electronic device, and this application does not impose any specific limitation on this.
[0071] Figure 3 Schematic diagram of a data synchronization system provided in an embodiment of the present application. The data synchronization system is applied to any type of electronic device mentioned above. Figure 3 FIG. 1 is a schematic diagram of a possible data synchronization system when the operating system of the electronic device is an Android operating system. Figure 3 As shown, the data synchronization system 300 may include an application layer, a system framework layer, a native layer, a hardware abstraction layer (HAL), a driver layer and a hardware layer.
[0072] The application layer may include a synchronization service application (i.e., a business data synchronization service application), which may include a functional module and a display module. The user may issue a corresponding functional instruction by touching the functional module, for example, the functional instruction may include: an instruction to obtain device information of the electronic device, an instruction to configure the transmission channel of the business synchronization data, an instruction to subscribe to the business synchronization data, etc.
[0073] In some embodiments, the display module may be a UI display page. The display module may be used to display relevant service data, such as device information of the electronic device, service data subscribed by the electronic device, and the like.
[0074] The system framework layer may include an application interface (data synchronization interface of the application layer) and a system service. The first business data synchronization service or the second business data service mentioned above may be a system service, for example.
[0075] In some embodiments, the system framework layer may receive functional instructions issued by the application layer through an application interface.
[0076] In some embodiments, the system service may include a functional service module, a device discovery service module, a business data synchronization service module, and a security and privacy service module. The configuration service module may implement the configuration function in response to the configuration instructions of the application layer. The configuration service module is used, for example, to configure subscription business data, configure data channels, etc. The device discovery service module may be used to control electronic devices to broadcast / scan to discover external electronic devices that meet the requirements. The business data synchronization service module may include a first synchronization protocol, and the business data synchronization service module may use the first synchronization protocol to encode the business data to generate first synchronization data. Of course, the business data synchronization service module may also parse the first synchronization data obtained from the outside to obtain the corresponding business data. The security and privacy service module may be used to encrypt the business data to ensure the security of data transmission.
[0077] In some embodiments, the Native layer and the hardware abstraction layer may serve as a data channel between the hardware layer and the system framework layer.
[0078] In some embodiments, the driving layer may include driving modules such as application chip driver, low power chip driver, and communication chip driver.
[0079] In some embodiments, the hardware layer may include an application processing chip (such as the first application chip or the second application chip mentioned above), a low-power chip (such as the first processing chip or the second processing chip mentioned above), and a communication chip (such as the first wireless communication chip or the second wireless communication chip mentioned above). It should be understood that the system framework layer can transmit data with the hardware layer through the driver layer.
[0080] In some embodiments, the hardware layer can establish a regular data channel (such as the second data channel and the fourth data channel mentioned above) between the application chip and the application layer, and the hardware layer can establish a low-power data channel (such as the first data channel and the third data channel mentioned above) between the low-power chip and the application layer. Compared with the application chip, the low-power chip (such as the microprocessor chip) has lower power consumption, so the data channel established by the low-power chip can also be called a low-power data channel.
[0081] In some embodiments, the conventional data channel may be a traditional Bluetooth data channel, a Bluetooth low energy data channel, or a Wi-Fi data channel, etc. The low energy transmission channel may be a Bluetooth low energy transmission channel.
[0082] In some embodiments, the first business data layer or the second business data layer mentioned above may be an application layer in the data synchronization system 300 .
[0083] It should be noted that Figure 3 The system framework layer, Native layer, HAL layer and driver layer shown in the figure may be collectively referred to as an intermediate layer (for example, the first intermediate layer 140 and the second intermediate layer 240 mentioned above).
[0084] Figure 4 Schematic diagram of another data synchronization system provided in an embodiment of the present application. The data synchronization system is applied to any type of electronic device mentioned above. Figure 4 The schematic diagram is a structural diagram of a possible data synchronization system when the operating system of the electronic device is the Windows operating system. Figure 4 The data synchronization system 400 and Figure 3 The data synchronization system 300 in the example has similar functions. For details, please refer to Figure 3 The description of the data synchronization system 300 is not repeated here.
[0085] It should be noted that there are some differences in the hierarchical division of the data synchronization system in the Windows operating system and the Android operating system. For example, in the Windows operating system, the data synchronization system 400 may include an application layer, a user layer, a kernel layer, and a hardware layer. Figure 3The functions of the system framework layer in are similar to those of Figure 3 The Native layer, HAL layer and driver layer in it.
[0086] In some embodiments, the user layer in the data synchronization system 400 may include a dynamic link library. The dynamic link library is similar to the system service function. The first business data synchronization service or the second business data service mentioned above may be a dynamic link library, for example.
[0087] In some embodiments, the first business data layer or the second business data layer mentioned above may be an application layer in the data synchronization system 400 .
[0088] Figure 5 1 is a schematic diagram of the structure of another data synchronization system provided in an embodiment of the present application. The data synchronization system is applied to any type of electronic device mentioned above. Figure 5 The figure is a schematic diagram of the structure of a possible data synchronization system when the electronic device does not support networking function.
[0089] See also Figure 5 , the data synchronization system 500 may include a task layer, a synchronization protocol layer, and a hardware layer. Tasks (i.e., business data) may be generated in the task layer, and the synchronization protocol layer may encode the task; the synchronization protocol layer may also receive external synchronization data and parse the synchronization data. The hardware layer may include a communication chip, and of course, an application chip and / or a low-power chip. Although, Figure 5 The data synchronization system in the data synchronization system cannot be connected to the Internet, but the data synchronization system can still synchronize data with external electronic devices. In some embodiments, the data synchronization system also includes a broadcast or scanning function, so that electronic devices outside the data synchronization system 500 can be discovered and connected without being connected to the Internet, so that data synchronization function can be achieved between external electronic devices.
[0090] In some embodiments, the task layer may include a Task module, and the Task module may generate task data. The Task module may include a business data synchronization and management unit. A user may issue corresponding functional instructions through the business data synchronization and management unit, for example, the functional instructions may include: device information acquisition instructions for electronic devices, transmission channel configuration instructions for business synchronization data, subscription instructions for business synchronization data, etc.
[0091] In some embodiments, the first business data layer or the second business data layer mentioned above may be a task layer.
[0092] In some embodiments, the synchronization protocol layer may include a shared function library, and the shared function library may encode or parse the relevant business data using the first synchronization protocol.
[0093] In some embodiments, the business data layer (for example, the first business data layer or the second business data layer mentioned above) may include a synchronization service application. Figure 6 The synchronization service application is described in detail with an example.
[0094] See also Figure 6 The synchronization service application may include a display module, a function module, an account system and a security framework system.
[0095] In some embodiments, business data (such as device parameters, scenario status, and other information of electronic devices) obtained through an intermediate layer (such as a system framework layer or a user layer, etc.) can be sent to a display module for UI display.
[0096] In some embodiments, the functional module may include a data acquisition unit, a data sending unit, a data receiving unit, a data processing unit, and a configuration unit. A user may issue a business data acquisition instruction through the data acquisition unit to obtain the status information of the electronic device; a user may send business data to an electronic device outside the data synchronization system through the data sending unit, and the business data may be, for example, device information of the electronic device; a user may receive business data sent by an electronic device outside the data synchronization system through the data receiving unit, and the business data may be, for example, device information of an external electronic device; a user may issue a data processing instruction through the data processing unit, and according to the instruction, for example, the business data may be packaged and processed. A user may issue a configuration instruction through the configuration unit, and the configuration instruction may include a data channel configuration instruction, a business data subscription instruction, etc., so as to realize channel selection and business data subscription.
[0097] In some embodiments, a user may obtain account information by sending an account request to an account system. In some embodiments, based on the account information, a security framework system may be used to generate key information to encrypt business data generated by the application layer, wherein the key information may be a symmetric key or an asymmetric key, and this application does not impose any specific restrictions on this.
[0098] In some embodiments, the middle layer (for example, the first middle layer or the second middle layer mentioned above) may include a business data service, which may refer to Figure 3 The following is combined with the system services Figure 7 The system service is described in detail with examples.
[0099] See also Figure 7The system service may include application interface, channel management service, business data management service, business data synchronization service, security and privacy service, etc. The application interface may include configuration interface, subscription interface, data sending and receiving interface, etc. The application layer may send corresponding functional instructions to the system service in the middle layer through the application interface.
[0100] In some embodiments, the application layer may configure the data channel configuration instructions issued by the configuration interface. In response to receiving the channel configuration instructions, the channel management service may be used to select a corresponding data channel (eg, a conventional data channel or a low-power data channel) for business data transmission.
[0101] In some embodiments, the application layer may issue a business data subscription instruction through a subscription interface, and in response to receiving the subscription instruction, the business data management service may be used to perform a business data subscription function. The business data management service may also be used to distribute business data to a business data synchronization service.
[0102] In some embodiments, the application layer may send a service data receiving and sending instruction through the data receiving and sending interface, and in response to the service data receiving and sending instruction, the service data synchronization service may be used to perform the service data receiving and sending function through the low power consumption channel. The service data synchronization service is also used to parse or encode the received and sent service data using the first synchronization protocol.
[0103] In some embodiments, in response to a business data encryption instruction issued by the application layer, the security and privacy management service can be used to encrypt the business synchronization data using key information to ensure the security of the business data.
[0104] In some embodiments, the hardware layer (for example, the first hardware layer or the second hardware layer mentioned above) may include application chips, low-power chips, and short-distance communication chips. Figure 8 The hardware layer is described in detail with examples.
[0105] See also Figure 8, the application chip (for example, the first application chip or the second application chip mentioned above) may include a first synchronization protocol. When a conventional data channel is selected for business data transmission, the application chip may use the first synchronization protocol to encode or parse the business synchronization data. The low-power chip (for example, the first processing chip or the second processing chip mentioned above) may include a first synchronization protocol. When a low-power data channel is selected for business data transmission, the low-power chip may use the first synchronization protocol to encode or parse the business synchronization data. It can be understood that by setting the first synchronization protocol in the application chip or the low-power chip, the processed data can be sent directly to the system service or an external electronic device without the need for the system service to process it. In this way, the processing pressure of the system service can be effectively alleviated, especially during the peak period of business data. The wireless communication chip may be, for example, a short-distance communication chip such as a Bluetooth chip or a Zifeng chip. Wireless data transmission can be performed between external electronic devices through the wireless communication chip.
[0106] Continue to see Figure 8 The low-power chip can also include business data management module, business data synchronization module, business data acquisition module, security and privacy module and data storage module.
[0107] In some embodiments, the business data management module can be used to subscribe to business data and distribute business data. When the low-power chip receives subscribed business data sent by an external electronic device, the business data management module is also used to send a new signaling (such as an interrupt signaling) to the application chip to wake up the application chip.
[0108] In some embodiments, the business data synchronization module includes a first synchronization protocol, and the business data synchronization module can be used to receive the first synchronization data sent by the external electronic device, and parse and process the first synchronization data using the first synchronization protocol to obtain the corresponding business data. The business data synchronization module is also used to receive the business data transmitted by the application layer, and encode the business data using the first synchronization protocol to obtain the first synchronization data, and then send the first synchronization data to the wireless communication chip. Furthermore, the first synchronization data can be transmitted to the external electronic device through the wireless communication chip.
[0109] In some embodiments, the business data acquisition module is also used to acquire business data such as device status, resource status, and scenario status of the electronic device, and transmit the acquired business data to the business data synchronization module.
[0110] In some embodiments, the security and privacy module may be used to encrypt business data processed in the business data synchronization module using secret key information.
[0111] In some embodiments, the business data processed by the business data synchronization module can be transmitted to the data storage module for data storage, for example, the device information of the external electronic device can be stored. When the business needs it, the storage module can be queried first to see if there is device information that meets the requirements. If there is device information that meets the requirements, the electronic device can be directly connected. In this way, the time for device discovery can be greatly shortened and the efficiency of device connection can be improved.
[0112] It should be noted that the low-power chip also includes scanning / broadcasting functions, so that the low-power chip can be used for all-weather device discovery.
[0113] In order to deepen the understanding of the data synchronization system in the embodiment of the present application, the following takes the device discovery scenario as an example. Fig. 9 The process of performing device discovery using the data synchronization system in the embodiment of the present application is described in detail with examples.
[0114] See also Fig. 9 , the user device can issue a device discovery instruction by triggering the device discovery module in the synchronization service application. The instruction can be transmitted to the system service through the application interface. In some embodiments, the trigger of device discovery can include but is not limited to: screen-on trigger, screen-off trigger, user-initiated trigger, subscription trigger, etc. of the electronic device. For example, a subscription trigger can be used to trigger a continuous device discovery process around the clock.
[0115] In response to receiving the device discovery instruction, the device discovery service in the system service can perform the device discovery function and send the execution instruction of the device discovery to the channel selection service. The channel selection service can select a data channel according to the execution instruction of the device discovery. In order to reduce the power consumption of electronic devices and improve the efficiency of device discovery, the channel selection service can be used to select a low-power data channel to perform the device discovery function. Then, the device discovery service can transmit the execution instruction of the device discovery to the low-power chip through the low-power channel, and use the broadcast function to discover external electronic devices that meet the requirements.
[0116] It should be noted that the use of low-power channels can enable all-weather device discovery, thereby improving the efficiency of device connection.
[0117] In order to deepen the understanding of the data synchronization system in the embodiment of the present application, the following takes the data interaction between electronic device 1 and electronic device 2 as an example. Fig.10 The data exchange process from the perspective of the electronic device is described in detail with examples. The data synchronization system in the electronic device 1 may include an account system, a security framework, an application APP, an application interface, a system service, a low-power chip, and a wireless communication chip, etc. Specifically, it may include steps: S1001 to S1017.
[0118] In step S1001: the electronic device 1 is turned on and the user can initiate an account request to the account system through the function page of the application.
[0119] In step S1002 : in response to receiving the account request, the account system may send account information to the application.
[0120] In step S1003: the application sends account information to the security framework.
[0121] In step S1004: Generate key information based on the account information, and send the key information to the application to encrypt the business data.
[0122] In step S1005: the user configures instructions to the low-power chip through the function page of the application program. For example, the low-power chip can configure the transmission parameters of the low-power channel according to the configuration instructions.
[0123] In step S1006: the low power function chip may send an ACK signaling indicating successful configuration to the application.
[0124] In step S1007: in response to receiving the ACK signaling, the user may send business data, such as context data, to the system service through the application.
[0125] In step S1008: the system service may select a low-power channel for business data transmission, and encode (also referred to as packaging) the business data using a first synchronization protocol, and then send the processed business data to the low-power chip through the low-power channel.
[0126] In step S1009: In some embodiments, in order to reduce processing pressure, the system service may not process the service data, and directly transmit the service data of the application to the low-power chip through the low-power channel. If the service data not processed by the system service is received, the low-power chip can package the service data using the first synchronization protocol and send the processed service data to the wireless communication chip.
[0127] In step S1010 : the wireless communication chip transmits the service data received from the low power consumption chip to the electronic device 2 via wireless communication.
[0128] In step S1011: the wireless communication chip will feed back an ACK signaling that has been sent successfully to the application.
[0129] In step S1012: the user sends a service subscription signaling to the low-power chip through the low-power channel.
[0130] In step S1013: according to the subscription service signaling, the low-power chip subscribes to the corresponding service data, and feeds back an ACK signaling indicating the successful subscription to the application.
[0131] In step S1014: the wireless communication chip receives the service synchronization data sent by the electronic device 2, and sends the service synchronization data to the low power consumption chip.
[0132] In step S1015: the low power chip parses the service synchronization data using the first synchronization protocol and stores the service synchronization data. Further, the low power chip can determine whether the service synchronization data is subscription service data. If it is subscription service data, a wake-up signaling is sent to the application to wake up the application chip.
[0133] In step S1016: the application sends an acquisition signaling to the low-power chip to obtain the subscription service.
[0134] In step S1017: the low-power chip matches the subscription service data acquisition signaling with the current service synchronization data type. If they match, the expected service synchronization data is transmitted to the application through the regular data channel to implement the service synchronization function.
[0135] Combination of the above Figures 1 to 10 The embodiment of the data synchronization system in the present application is described in detail. Figure 11 to Figure 12 The method embodiment of the present application is described in detail. It should be understood that the description of the method embodiment corresponds to the description of the data synchronization system embodiment, so for the parts not described in detail, reference can be made to the foregoing data synchronization system embodiment.
[0136] Fig.11 The method is applied to a first electronic device and is used to perform data interaction with a second electronic device outside the first electronic device. The method includes steps S1120 to S1160.
[0137] In step S1120: business data is generated using the first business data layer in the data synchronization system.
[0138] In step S1140: the service data is encoded using the first synchronization protocol of the first intermediate layer in the data synchronization system to obtain first synchronization data.
[0139] In step S1160: the first synchronization data is sent to the second electronic device by utilizing the first hardware layer in the data synchronization system.
[0140] Optionally, the first intermediate layer includes a first business data synchronization service, and the process of encoding the business data using the first synchronization protocol of the first intermediate layer in the data synchronization system to obtain first synchronization data includes: encoding the business data using the first synchronization protocol in the first business data synchronization service to obtain the first synchronization data.
[0141] Optionally, the method also includes: using the business data synchronization service to obtain status information of the first electronic device; wherein the status information of the first electronic device includes one or more of the following status information: device status of the first electronic device, resource status of the first electronic device, and scenario status of the first electronic device.
[0142] Optionally, the first business data layer includes a business data synchronization service application. Before obtaining the status information of the first electronic device, the method also includes: in response to a user triggering a function to obtain the status information of the first electronic device, using the business data synchronization service application to send a first instruction to the business data synchronization service; wherein the first instruction is used to instruct the acquisition of the status information of the first electronic device.
[0143] Optionally, before encoding the service data using the first synchronization protocol, the method further includes: configuring the subscription service data of the first electronic device using the service data synchronization service.
[0144] Optionally, the first hardware layer includes: a first processing chip, which establishes a first data channel with the first business data layer; a first application chip, which establishes a second data channel with the first business data layer; a first wireless communication chip, which is connected to both the first data channel and the second data channel; the method also includes: in response to the first synchronization data being subscription business data, using the business data synchronization service to transmit the first synchronization data to the first communication chip through the second data channel; in response to the first synchronization data being non-subscription business data, using the business data synchronization service to transmit the first synchronization data to the first communication chip through the first data channel.
[0145] Fig.12 A flowchart of a method for using a data synchronization system provided in another embodiment of the present application. The method is applied to a second electronic device, and the method is used to interact with a first electronic device outside the second electronic device. The method includes: steps S1220 to S1260
[0146] In step S1220: using the second hardware layer in the data synchronization system to receive the first synchronization data sent by the first electronic device.
[0147] In step S1240: the first synchronization data is parsed and processed using the first synchronization protocol of the second intermediate layer in the data synchronization system to obtain business data.
[0148] In step S1260: the business data is acquired from the second intermediate layer using the second business data layer in the data synchronization system.
[0149] Optionally, the second intermediate layer includes a second business data synchronization service, and the use of the first synchronization protocol of the second intermediate layer in the data synchronization system to parse and process the first synchronization data to obtain the business data includes: using the first synchronization protocol in the second business data synchronization service to parse and process the first synchronization data to obtain the business data.
[0150] Optionally, the second hardware layer includes: a second processing chip, establishing a third data channel with the second business data layer; a second application chip, establishing a fourth data channel with the second business data layer; a second wireless communication chip, connected to both the third data channel and the fourth data channel; the method also includes: using the second wireless communication chip to transmit the first synchronization data to the second intermediate layer through the third data channel or the fourth data channel.
[0151] Optionally, the use of the second wireless communication chip to transmit the first synchronization data to the second intermediate layer through the third data channel or the fourth data channel includes: in response to the first synchronization data being the subscription service data of the second electronic device, using the second processing chip to send a wake-up signaling to the second application chip to wake up the second application chip, and controlling the second wireless communication chip to transmit the first synchronization data to the second intermediate layer through the fourth data channel; or in response to the first synchronization data being the non-subscription service data of the second electronic device, controlling the second wireless communication chip to transmit the first synchronization data to the second intermediate layer through the third data channel.
[0152] Optionally, before receiving the first synchronization data sent by the first electronic device, the method further includes: configuring the subscription service data of the second electronic device by using the second service data synchronization service.
[0153] An embodiment of the present application provides an electronic device, such as Fig.13 As shown, the electronic device 1300 may include a data synchronization system 1310. The electronic device 1300 may refer to any type of electronic device mentioned above, and the data synchronization system 1310 may refer to any type of data synchronization system mentioned above.
[0154] Another embodiment of the present application provides an electronic device, such as Fig.14 The electronic device 1400 may be used to implement the method described in the above method embodiment.
[0155] It should be understood that the electronic device 1400 can be applied to any type of electronic device mentioned above.
[0156] The electronic device 1400 may include one or more processors 1410. The processor 1410 may support the electronic device 1400 to implement the method described in the foregoing method embodiment.
[0157] The processor 1410 may be a general-purpose processor or a special-purpose processor. For example, the processor may be a central processing unit (CPU). Alternatively, the processor may also be other general-purpose processors, digital signal processors (DSP), application specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0158] The electronic device 1400 may further include one or more memories 1420. The memory 1420 stores a program, which can be executed by the processor 1410 to control the electronic device 1400 to execute the method described in the above method embodiment. The memory 1420 may be independent of the processor 1410 or integrated in the processor 1410.
[0159] The memory 1420 may be a volatile memory or a nonvolatile memory, or may include both volatile and nonvolatile memories. Among them, the nonvolatile memory may be a read-only memory (ROM), a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), which is used as an external cache. By way of example but not limitation, the memory 1420 may also be various types of random access memory (RAM), such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous-link DRAM (SLDRAM) and direct ram-bus RAM (DR RAM).
[0160] The electronic device 1400 may further include a transceiver 1430. The processor 1410 may communicate with other devices through the transceiver 1430. For example, the processor 1410 may transmit and receive data with other devices through the transceiver 1430.
[0161] The present application also provides a chip in an embodiment, including a processor, which can be used to call and run a computer program from a memory, so that a device equipped with the chip performs the method described in the above method embodiment. It is understood that the processor can be any type of processor mentioned above. It is understood that the memory can be independent of the chip or integrated in the chip.
[0162] The embodiment of the present application also provides a machine-readable storage medium for storing a program, and the program enables a computer to execute the methods in the various method embodiments of the present application.
[0163] The embodiment of the present application also provides a computer program product. The computer program product includes a program. The program enables a computer to execute the methods in the various method embodiments of the present application.
[0164] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any other combination. When implemented by 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 disclosure is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a machine-readable storage medium, or transmitted from one machine-readable storage medium to another machine-readable storage medium. For example, the computer instructions can be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (Digital Subscriber Line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The machine-readable storage medium can 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 integrations. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a digital video disc (DVD)), or a semiconductor medium (eg, a solid state disk (SSD)).
[0165] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments of the present disclosure can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present disclosure.
[0166] In the several embodiments provided in the present disclosure, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the 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.
[0167] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0168] In addition, each functional unit in each embodiment of the present disclosure may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0169] The above is only a specific embodiment of the present disclosure, but the protection scope of the present disclosure is not limited thereto. Any person skilled in the art who is familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present disclosure, which should be included in the protection scope of the present disclosure. Therefore, the protection scope of the present disclosure should be based on the protection scope of the claims.
Claims
1. A data synchronization system, characterized in that: The data synchronization system is applied to a first electronic device, and the data synchronization system is used to perform data interaction with a second electronic device outside the first electronic device, and the data synchronization system includes: The first business data layer is used to generate business data; A first intermediate layer, comprising a first synchronization protocol, wherein the first intermediate layer is used to encode the service data using the first synchronization protocol to obtain first synchronization data; The first hardware layer is used to send the first synchronization data to the second electronic device.
2. The data synchronization system according to claim 1, characterized in that: The first intermediate layer comprises: The first business data synchronization service is used to encode the business data using the first synchronization protocol to obtain the first synchronization data.
3. The data synchronization system according to claim 2, characterized in that: The first business data synchronization service is also used for: Acquire status information of the first electronic device; The state information of the first electronic device includes one or more of the following state information: a device state of the first electronic device, a resource state of the first electronic device, and a context state of the first electronic device.
4. The data synchronization system according to claim 3, characterized in that: The first service data layer includes: a business data synchronization service application, configured to send a first instruction to the first business data synchronization service in response to a user triggering a function of acquiring the state information of the first electronic device before acquiring the state information of the first electronic device; The first instruction is used to instruct obtaining status information of the first electronic device.
5. The data synchronization system according to claim 2, characterized in that: The first business data synchronization service is also used for: Before encoding the service data using the first synchronization protocol, the subscription service data of the first electronic device is configured.
6. The data synchronization system according to claim 5, characterized in that: The first hardware layer includes: A first processing chip, used to establish a first data channel with the first service data layer; A first application chip, used to establish a second data channel with the first service data layer; A first wireless communication chip, connected to both the first data channel and the second data channel; The first business data synchronization service is also used to transmit the first synchronization data to the first communication chip through the second data channel in response to the first synchronization data being subscription business data; and to transmit the first synchronization data to the first communication chip through the first data channel in response to the first synchronization data being non-subscription business data.
7. The data synchronization system according to any one of claims 1 to 6, characterized in that: If the operating system of the first electronic device is an Android operating system, the first service data layer is an application layer, the first intermediate layer is a system framework layer, and the first hardware layer is a hardware layer; If the operating system of the first electronic device is a Windows operating system, the first service data layer is an application layer, the first intermediate layer is a user layer, and the first hardware layer is a hardware layer; If the first electronic device does not support a networking function, the first service data layer is a task layer, the first intermediate layer is a synchronization protocol layer, and the first hardware layer is a hardware layer.
8. A data synchronization system, characterized in that: The data synchronization system is applied to a second electronic device, and the data synchronization system is used to perform data interaction with a first electronic device outside the second electronic device, and the data synchronization system includes: A second hardware layer, configured to receive first synchronization data sent by the first electronic device; A second intermediate layer includes a first synchronization protocol, and the second intermediate layer is used to parse and process the first synchronization data using the first synchronization protocol to obtain business data; The second business data layer is used to obtain the business data from the second intermediate layer.
9. The data synchronization system according to claim 8, characterized in that: The second intermediate layer comprises: The second business data synchronization service is used to parse and process the first synchronization data using the first synchronization protocol to obtain the business data.
10. The data synchronization system according to claim 9, characterized in that: The second hardware layer includes: A second processing chip, used to establish a third data channel with the second service data layer; A second application chip, used to establish a fourth data channel with the second service data layer; A second wireless communication chip is connected to both the third data channel and the fourth data channel, and is used to transmit the first synchronization data to the second intermediate layer through the third data channel or the fourth data channel.
11. The data synchronization system according to claim 10, characterized in that: The second processing chip is used for sending a wake-up signaling to the second application chip in response to the first synchronization data being subscription service data of the second electronic device, so as to wake up the second application chip; The second business data synchronization service is also used for: In response to the first synchronization data being the subscribed service data of the second electronic device and the second application chip being in an awake state, the first synchronization data is received through the fourth data channel; in response to the first synchronization data being the non-subscribed service data of the second electronic device, the first synchronization data is received through the third data channel.
12. The data synchronization system according to claim 9, characterized in that: The second business data synchronization service is also used for: Before receiving the first synchronization data sent by the first electronic device, the subscription service data of the second electronic device is configured.
13. The data synchronization system according to any one of claims 8 to 12, characterized in that: If the operating system of the second electronic device is an Android operating system, the second service data layer is an application layer, the second intermediate layer is a system framework layer, and the second hardware layer is a hardware layer; If the operating system of the second electronic device is a Windows operating system, the second service data layer is an application layer, the second intermediate layer is a user layer, and the second hardware layer is a hardware layer; If the second electronic device does not support the networking function, the second service data layer is a task layer, the second intermediate layer is a synchronization protocol layer, and the second hardware layer is a hardware layer.
14. A method for using a data synchronization system, characterized in that: The method is applied to a first electronic device, and the method is used to perform data interaction with a second electronic device outside the first electronic device, and the method includes: generating business data using the first business data layer in the data synchronization system; The service data is encoded using a first synchronization protocol of a first intermediate layer in the data synchronization system to obtain first synchronization data; The first synchronization data is sent to the second electronic device by using a first hardware layer in the data synchronization system.
15. A method for using a data synchronization system, characterized in that: The method is applied to a second electronic device, and the method is used to perform data interaction with a first electronic device outside the second electronic device, and the method includes: Receiving first synchronization data sent by the first electronic device using a second hardware layer in the data synchronization system; Parsing and processing the first synchronization data using the first synchronization protocol of the second intermediate layer in the data synchronization system to obtain business data; The business data is acquired from the second intermediate layer using the second business data layer in the data synchronization system.
16. An electronic device, characterized in that: It comprises the data synchronization system as claimed in any one of claims 1 to 7 or the data synchronization system as claimed in any one of claims 8 to 13.
17. A computer-readable storage medium having executable code stored thereon, characterized in that: The code is used to implement the method according to claim 14 or the method according to claim 15.