Remote control method, electronic device, and communication system
By using a secondary processor in the controlled device to establish a long-term connection with the server, and switching to the primary processor to communicate with the server when necessary, the problem of the controlled device being unable to receive remote control commands when not powered on is solved, thus achieving stable and efficient remote control.
Patent Information
- Application Number
- CN202310809701.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-30
- Publication Date
- 2026-11-27
- Estimated Expiration
- 2043-06-30
AI Technical Summary
In existing technologies, the controlled device cannot successfully receive or respond to remote control commands when it is not powered on, resulting in the failure of the remote control function.
After the controlled device is powered off, a long connection is established with the server through the secondary processor, and a communication connection is established with the server through the main processor when needed, so as to ensure that remote control commands can be received and responded to in different states (such as power off, hibernation, sleep or power-on failure state).
It enables stable reception of remote control commands in more scenarios, ensuring the effectiveness of remote control, extending the lifespan of the secondary processor, reducing write losses, and avoiding user-perceived anomalies.
Smart Images

Figure CN119232779B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of terminals, and more particularly to a remote control method, electronic device, and communication system. Background Technology
[0002] With the development of terminal technology, users can remotely control the controlled device to perform various tasks through the master control device. In order to realize the above remote control function, it is necessary to ensure that the controlled device can successfully receive the remote control command and respond successfully.
[0003] However, in practical applications, the controlled device may fail to receive remote control commands or respond successfully in certain states, such as when it is not powered on, or when it is powered on but cannot respond normally due to software or hardware failures.
[0004] Therefore, ensuring the effectiveness of remote control functions is an urgent problem to be solved. Summary of the Invention
[0005] This application discloses a remote control method, electronic device, and communication system. The method is applied to a communication system including a master control device, a controlled device, and a server. After the controlled device is powered off, it establishes a long connection with the server through a secondary processor and enables the secondary processor to reconnect. When the controlled device is powered off, if it receives a remote power-on command from the master control device forwarded by the server based on this long connection, it controls the master processor to start via the secondary processor, then first controls the secondary processor to disable the reconnection function via the master processor, and finally establishes a communication connection with the server via the master processor. Conversely, when the controlled device is powered off, if it detects a power-on operation, it directly controls the master processor to start, then first controls the secondary processor to disable the reconnection function via the master processor, and finally establishes a communication connection via the master processor. The controlled device can achieve remote control through the communication connection between the master processor and the server.
[0006] In a first aspect, this application provides an electronic device, comprising: a main processor and a secondary processor, wherein the performance of the main processor is superior to that of the secondary processor; the secondary processor is configured to, when the main processor is in a non-working state, establish a first connection with a server, receive a first instruction sent by the server based on the first connection, and, in response to the first instruction, notify the main processor to switch to a working state; the main processor is configured to, after switching to a working state, disable the reconnection function of the secondary processor, establish a second connection with the server, and disconnect the first connection upon the establishment of the second connection; wherein the reconnection function includes: after the first connection is disconnected, the secondary processor re-establishes the first connection with the server.
[0007] Implementing the method provided in the first aspect enables more remote control scenarios and improves the stability of remote connections through reconnection functionality. Specifically, when electronic devices are powered off, in sleep, hibernation, or powered on but malfunctioning, they can establish a persistent connection with the server through the secondary processor and receive and respond to remote control commands from the primary control device forwarded by the server based on this persistent connection. When the electronic device is powered on, the controlled device can establish a connection with the server through the primary processor and receive and respond to remote control commands from the primary control device forwarded by the server based on this connection. On the one hand, when the controlled device is powered off, in hibernation, hibernation, or powered on but malfunctioning, the secondary processor of the controlled device automatically activates the reconnection function, allowing it to re-request the establishment of a persistent connection with the server if the secondary processor abnormally disconnects, thereby ensuring the stability of the persistent connection between the secondary processor and the server. For example, if the secondary processor is powered off and then powered on again, the power outage will cause the persistent connection to be broken, but after power is restored, the secondary processor can automatically request the establishment of a persistent connection with the server.
[0008] On the other hand, when the controlled device is powered on, the main processor of the controlled device will first notify the secondary processor to disable the reconnection function, and then establish a communication connection between the main processor and the server to automatically disconnect the connection between the secondary processor and the server. In this way, the communication connection between the main processor and the server is seamlessly connected to the long connection between the secondary processor and the server, ensuring that the controlled device and the server are always connected, so that the user has no abnormal perception on the main control device. It can also prevent the secondary processor from being directly squeezed out by the main processor, triggering the reconnection function of the secondary processor, and causing the secondary processor to compete for the connection to the server.
[0009] In conjunction with the electronic device described in the first aspect, the secondary processor is further configured to determine that the primary processor is in a non-operating state after a timeout in which no bus heartbeat message is received from the secondary processor; or, the secondary processor is further configured to determine that the primary processor is in a non-operating state after receiving a second instruction sent by the primary processor.
[0010] In this way, the secondary processor can determine the status of the primary processor in multiple ways, and thus establish a remote connection with the Rain server.
[0011] In conjunction with the electronic device described in the first aspect, the non-working state of the main processor includes any one of the following: the main processor is powered off, the main processor is powered on and faulty, and the main processor is in a working state including the main processor being powered on and not faulty.
[0012] In conjunction with the electronic device described in the first aspect, the first instruction includes instructions sent by the server for powering on, waking from hibernation, waking from sleep, or restarting.
[0013] In conjunction with the electronic device described in the first aspect, the electronic device also includes an embedded control processor (EC); the sub-processor is specifically used to notify the main processor to switch to the working state via the EC.
[0014] In conjunction with the electronic device described in the first aspect, the main processor is further configured to send a network identifier and a first password to the sub-processor when it is in an operating state; the sub-processor is further configured to access the network based on the network identifier and the first password when the main processor is not in an operating state.
[0015] In conjunction with the electronic device described in the first aspect, the main processor is further configured to, when in an operating state, send a login account and a second password to the sub-processor, and establish a second connection based on the login account and the second password; the sub-processor is further configured to, when the main processor is not in an operating state, establish a first connection based on the login account and the second password.
[0016] In conjunction with the electronic device described in the first aspect, the main processor is further configured to send a device capability description file to the sub-processor when it is in an operating state; the sub-processor is further configured to parse a first instruction based on the device capability description file when the main processor is not in an operating state.
[0017] In conjunction with the electronic device described in the first aspect, the main processing is further configured to perform the following: querying information from the sub-processor; if the information in the sub-processor does not include the first information, then sending the first information to the sub-processor, the first information including any one or more of the following: network identifier and first password, login account and second password, or, device capability description file.
[0018] This reduces write overhead on the secondary processor and extends its lifespan. Specifically, because the secondary processor has lower specifications, the number of write cycles to its integrated NVM (e.g., flash memory) is limited. Therefore, before each information synchronization, the controlled device needs to query the secondary processor through the main processor to see if the information is consistent with the information to be synchronized. Only if there is a discrepancy will the information be written to the secondary processor.
[0019] In conjunction with the electronic device described in the first aspect, the secondary processor is also used to perform the following: if the secondary processor is powered off, the first connection is disconnected; if the secondary processor does not receive a bus heartbeat message from the primary processor after being powered off and then powered on again, the secondary processor re-establishes the first connection with the server.
[0020] In conjunction with the electronic device described in the first aspect, the main processing is also configured to notify the subprocessor to clear the data in the random access memory (RAM) after establishing a second connection with the server.
[0021] This reduces the power consumption of the secondary processor, allowing it to enter a low-power state while the main processor is working.
[0022] In conjunction with the electronic device described in the first aspect, the main processing is also configured to perform the following after establishing a second connection with the server:
[0023] The main processor receives a third instruction from the server based on the second connection. The third instruction includes instructions to shut down, sleep, hibernate, restart, or play music. In response to the third instruction, the main processor executes the corresponding task.
[0024] In conjunction with the electronic device described in the first aspect, the secondary processor includes a configuration management module, which is used to determine the operating status of the primary processor based on the bus heartbeat message of the primary processor.
[0025] In conjunction with the electronic device described in the first aspect, the secondary processor includes a remote connection management module, which is used to establish a first connection with the server and receive a first instruction based on the first connection.
[0026] In conjunction with the electronic device described in the first aspect, the secondary processor includes a wake-up management module, which is used to notify the main processor to switch to the working state.
[0027] Secondly, this application provides a remote control method applied to an electronic device, which includes a main processor and a secondary processor, wherein the performance of the main processor is superior to that of the secondary processor. The method includes: when the electronic device determines that the main processor is in a non-working state, it establishes a first connection with a server through the secondary processor, and receives a first instruction sent by the server based on the first connection; in response to the first instruction, it notifies the main processor to switch to a working state through the secondary processor; after the main processor of the electronic device switches to a working state, it disables the reconnection function of the secondary processor through the main processor, and establishes a second connection with the server through the main processor; when the second connection is established, the first connection is disconnected; wherein the reconnection function includes: re-establishing the first connection with the server through the secondary processor after the first connection is disconnected.
[0028] In conjunction with the method provided in the second aspect, the electronic device determines that the main processor is in a non-working state by: the electronic device's secondary processor determining that the main processor is in a non-working state after a timeout period without receiving a bus heartbeat message from the secondary processor; or, the electronic device's secondary processor determining that the main processor is in a non-working state after receiving a second instruction sent by the main processor.
[0029] In conjunction with the method provided in the second aspect, the non-working state of the main processor includes any one of the following: the main processor is powered off, the main processor is powered on and faulty, and the main processor is in a working state, including the main processor is powered on and not faulty.
[0030] In conjunction with the method provided in the second aspect, the first instruction includes instructions sent by the server for powering on, waking from hibernation, waking from sleep, or restarting.
[0031] In conjunction with the method provided in the second aspect, the electronic device also includes an embedded control processor (EC); the electronic device notifies the main processor to switch to the working state through the sub-processor, specifically including: the electronic device notifies the main processor to switch to the working state through the sub-processor and the EC.
[0032] In conjunction with the method provided in the second aspect, the method further includes: when the main processor of the electronic device is in a working state, the electronic device sends a network identifier and a first password to the sub-processor through the main processor; when the main processor of the electronic device is not in a working state, the sub-processor of the electronic device accesses the network based on the network identifier and the first password.
[0033] In conjunction with the method provided in the second aspect, the method further includes: when the main processor of the electronic device is in a working state, the electronic device sends a login account and a second password to the sub-processor through the main processor, and establishes a second connection through the main processor based on the login account and the second password; when the main processor of the electronic device is not in a working state, the sub-processor of the electronic device establishes a first connection based on the login account and the second password.
[0034] In conjunction with the method provided in the second aspect, the method further includes: when the main processor of the electronic device is in an active state, the electronic device sends a device capability description file to the sub-processor through the main processor; when the main processor of the electronic device is in an inactive state, the sub-processor of the electronic device parses out the first instruction based on the device capability description file.
[0035] In conjunction with the method provided in the second aspect, the method further includes: before the electronic device establishes a first connection with the server through the sub-processor, the method further includes: the electronic device queries the information of the sub-processor through the main processor; if the information in the sub-processor does not include the first information, the main processor sends the first information to the sub-processor, the first information including any one or more of the following: network identifier and first password, login account and second password, or, device capability description file.
[0036] In conjunction with the method provided in the second aspect, before the electronic device establishes a first connection with the server through the secondary processor, the method further includes: if the secondary processor is powered off, the first connection is disconnected; if the electronic device does not receive a bus heartbeat message from the main processor through the secondary processor after the secondary processor is powered off and then powered on again, the first connection is re-established with the server through the secondary processor.
[0037] In conjunction with the method provided in the second aspect, after the electronic device establishes a second connection with the server through the main processor, the method further includes: instructing the subprocessor to clear the data in the random access memory (RAM) through the main processor.
[0038] In conjunction with the method provided in the second aspect, after the electronic device establishes a second connection with the server through the main processor, the method further includes: the electronic device receiving a third instruction sent by the server through the main processor based on the second connection, the third instruction including instructions to power off, sleep, hibernate, restart, or play music; and in response to the third instruction, executing the corresponding task through the main processor.
[0039] In conjunction with the method provided in the second aspect, the secondary processor includes a configuration management module, and the electronic device specifically determines the working status of the main processor based on the bus heartbeat message of the main processor through the configuration management module.
[0040] In conjunction with the method provided in the second aspect, the sub-processor includes a remote connection management module, and the electronic device specifically establishes a first connection with the server through the remote connection management module and receives a first instruction based on the first connection.
[0041] In conjunction with the method provided in the second aspect, the secondary processor includes a wake-up management module, through which the electronic device specifically notifies the main processor to switch to the working state.
[0042] Thirdly, this application provides a chip that is applied to an electronic device and is used to invoke computer instructions to cause the electronic device to perform the methods described in any of the second aspects.
[0043] Fourthly, this application provides a computer-readable storage medium including instructions that, when executed on an electronic device, cause the electronic device to perform the method described in any of the second aspects. Attached Figure Description
[0044] Figure 1 A schematic diagram of the architecture of a communication system 10 provided in an embodiment of this application;
[0045] Figure 2 A schematic diagram of the hardware architecture of a main control device provided in an embodiment of this application;
[0046] Figure 3A This application provides a schematic diagram of the hardware architecture of a controlled device.
[0047] Figure 3B A schematic diagram of the software architecture of a controlled device provided in an embodiment of this application;
[0048] Figure 4 A schematic diagram of a server hardware architecture provided for an embodiment of this application;
[0049] Figures 5A-5D A set of schematic diagrams of the operation interface for normal shutdown of controlled devices provided in the embodiments of this application;
[0050] Figures 6A-6G A set of schematic diagrams of operation interfaces for remotely controlling the power-on of a controlled device via a master control device, provided for embodiments of this application;
[0051] Figures 7A-7C A set of schematic diagrams of operation interfaces for controlling the power-on of the controlled device through local operation are provided for embodiments of this application;
[0052] Figures 8A-8F A schematic diagram illustrating a scenario where a set of controlled device sub-processors loses power and then regains power, as provided in an embodiment of this application.
[0053] Figure 9 A flowchart of a remote control method provided in this application;
[0054] Figure 10 A flowchart of inter-device interaction provided in this application;
[0055] Figure 11 This application provides an embodiment of an interaction process for synchronizing information between primary and secondary processors.
[0056] Figure 12 This application provides an embodiment of an interactive process for remote control via a secondary processor of the main control device after an abnormal / normal shutdown.
[0057] Figure 13 This application provides an embodiment of an interactive process for remote control via the main processor of the main control device after remote / local power-on.
[0058] Figure 14 This application describes an interactive process for remote control of a main control device after the secondary processor of the main control device loses power and is restored to power. Detailed Implementation
[0059] The technical solutions in the embodiments of this application will be clearly and thoroughly described below with reference to the accompanying drawings. In the description of the embodiments of this application, unless otherwise stated, " / " means "or," for example, A / B can mean A or B; the word "and / or" in the text is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone.
[0060] Hereinafter, the terms "first" and "second" are used for descriptive purposes only and should not be construed as implying or suggesting relative importance or implicitly indicating the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature, and in the description of the embodiments of this application, unless otherwise stated, "multiple" means two or more.
[0061] In this application, the reference to "embodiment" means that a specific feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a mutually exclusive, independent, or alternative embodiment. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described in this application can be combined with other embodiments.
[0062] The term "user interface (UI)" used in the following embodiments of this application refers to the medium interface through which an application or operating system interacts and exchanges information with the user. It realizes the conversion between the internal form of information and the form that the user can accept. The user interface is source code written in a specific computer language such as Java or Extensible Markup Language (XML). The interface source code is parsed and rendered on the electronic device, ultimately presenting content that the user can recognize. A common form of user interface is the graphical user interface (GUI), which refers to a user interface related to computer operation displayed graphically. It can be visible interface elements such as text, icons, buttons, menus, tabs, text boxes, dialog boxes, status bars, navigation bars, and widgets displayed on the screen of an electronic device.
[0063] In one possible remote control method, the master control device can send remote control commands to the controlled device through the server to achieve the remote control function only when the controlled device is powered on.
[0064] This is because when the controlled device is powered on, its processor is powered on and can operate. The controlled device can log in to the server through the processor, and therefore receive remote control commands sent by the master device from the server, and successfully respond to those commands. However, when the controlled device is not powered on, its processor is powered off or stops working, and the controlled device cannot log in to the server through the processor. Therefore, the controlled device cannot receive remote control commands sent by the master device from the server through the processor, and thus cannot successfully respond to those commands.
[0065] It is evident that the above remote control methods cannot achieve remote control functionality for controlled devices that are not powered on, such as those in a powered-off, hibernation, or sleep state.
[0066] Therefore, this application provides a remote control method, an electronic device, and a communication system. The remote control method is applied to a communication system comprising a master control device, a controlled device, and a server. The controlled device includes a main processor and a sub-processor, the sub-processor integrating a chip for implementing wireless communication functions.
[0067] In this method, after the controlled device's secondary processor determines that the controlled device is powered off, the controlled device establishes a long connection with the server through the secondary processor and enables the secondary processor to reconnect. When the controlled device is powered off, if it receives a remote power-on command from the primary device forwarded by the server based on this long connection, it controls the primary processor to start via the secondary processor, then first controls the secondary processor to disable the reconnection function via the primary processor, and finally establishes a communication connection with the server via the primary processor. Conversely, if the controlled device detects a power-on operation while powered off, it directly controls the primary processor to start, then first controls the secondary processor to disable the reconnection function via the primary processor, and finally establishes a communication connection via the primary processor. The controlled device can achieve remote control through the communication connection between the primary processor and the server.
[0068] Several key concepts involved in this application include:
[0069] Long connections are the opposite of short connections. A short connection means that the controlled device and the server establish a connection each time data needs to be sent, and close the connection after the data transmission is complete; that is, each connection is used only for one data transmission operation. A long connection means that the controlled device and the server do not close the connection after establishing it and sending data, but maintain the connection. Subsequent data transmissions can be made directly through this maintained connection. With a long connection, the controlled device and server can continuously send multiple data packets over a single connection. Furthermore, if no data packets are sent for an extended period during the long connection period, the controlled device and server typically need to monitor the current communication link to detect any failures.
[0070] The reconnection function includes the ability for the secondary processor to automatically re-request the establishment of the long-term connection with the server after the secondary processor loses its connection. For example, if the secondary processor suddenly disconnects, causing the long-term connection with the server to break, it will automatically trigger a re-request to establish the long-term connection with the server after power is restored.
[0071] In this embodiment, except that after the controlled device determines that the controlled device is powered off, the controlled device establishes a long connection with the server through the subprocessor to achieve remote power-on, the controlled device can also establish a long connection with the server through the subprocessor to achieve remote function as long as the subprocessor determines that the main processor is not in a working state.
[0072] The main processor being in a non-working state includes, but is not limited to, the controlled device being powered off, hibernating, sleeping, or powered on but malfunctioning. Specifically, when the controlled device is confirmed to be in hibernation or sleep mode, it establishes a long connection with the server through the secondary processor to achieve remote wake-up; or when the controlled device is confirmed to be powered on but malfunctioning, it establishes a long connection with the server through the secondary processor to achieve remote restart.
[0073] The main processor is considered operational when the controlled device is powered on but not malfunctioning. Specifically, when the controlled device is powered on, the main processor is also powered on and thus meets the conditions for operation. Furthermore, if the controlled device is not malfunctioning, the main processor can operate normally. Typically, regardless of whether the main processor is in an inactive or operational state, the secondary processor is also in an operational state.
[0074] In one feasible approach, the method by which the controlled device determines that the main processor is in a non-working state through the sub-processor includes, but is not limited to:
[0075] (1) Determined based on notifications sent by the main processor to the sub-processor. When the main processor receives a power-off, hibernation, or sleep input, it notifies the sub-processor to log in to the server, i.e., to establish a long connection between the sub-processor and the server, so that the sub-processor can determine that the main processor is in a non-working state. The power-off, hibernation, or sleep input received by the main processor can be an operation applied to the controlled device, or a remote control command sent by the server to the main processor.
[0076] (2) Determined based on the bus heartbeat status between the master processor and the slave processor. When the master processor is in an active state, it periodically sends bus heartbeat messages to the slave processor. If the slave processor does not receive a bus heartbeat message within a timeout period, it confirms that the master processor is in an inactive state. The bus heartbeat message is used to maintain the bus connection between the master processor and the slave processor, enabling the master processor to send control commands to the slave processor through the bus connection.
[0077] (3) The status of the controlled device is determined based on the status of the controlled device sent by the embedded controller (EC) to the sub-processor. Specifically, the controlled device also includes the EC, which can periodically or when the status of the controlled device changes, so that the sub-processor can confirm that the main processor is in a non-working state.
[0078] In another feasible approach, before the controlled device establishes a long-lived connection with the server via the secondary processor, it needs to synchronize information with the secondary processor via the primary processor. The information to be synchronized includes, but is not limited to, connection configuration information and device configuration information. Connection configuration information is used by the secondary processor to establish a long-lived connection with the server using the same server login information as the primary processor. Device configuration information is used by the secondary processor to access the network after obtaining network configuration information, and also to allow the secondary processor to understand the capabilities of the controlled device, enabling it to parse and respond to remote control commands upon receipt. Specifically, before each information synchronization, the controlled device first needs to query the secondary processor via the primary processor to see if the information is consistent with the information to be synchronized. If they are inconsistent, the information is then written to the secondary processor's non-volatile memory (NVM).
[0079] As can be seen, implementing the remote control method provided in this application can ensure the effectiveness of remote control in many ways, and specifically brings the following technical effects:
[0080] (1) Enables more remote control scenarios. Specifically, when the controlled device is powered off, in sleep or hibernation mode, or powered on but malfunctioning, the controlled device can establish a long connection with the server through the secondary processor, and receive and respond to remote control commands from the master device forwarded by the server based on this long connection. When the controlled device is powered on, it can establish a connection with the server through the main processor, and receive and respond to remote control commands from the master device forwarded by the server based on this connection.
[0081] (2) Ensure that the controlled equipment reliably receives remote control commands. Specifically:
[0082] On the one hand, when the controlled device is powered off, in hibernation, in sleep mode, or powered on but malfunctioning, the secondary processor of the controlled device automatically activates the reconnection function. This allows the secondary processor to re-request the establishment of a long-term connection with the server when it is abnormally disconnected, thereby ensuring the stability of the long-term connection between the secondary processor and the server. For example, if the secondary processor is powered off and then powered on again, the power outage will cause the long-term connection to be broken, but after power is restored, the secondary processor can automatically request the establishment of a long-term connection with the server.
[0083] On the other hand, when the controlled device is powered on, the main processor of the controlled device will first notify the secondary processor to disable the reconnection function, and then establish a communication connection between the main processor and the server to automatically disconnect the connection between the secondary processor and the server. In this way, the communication connection between the main processor and the server is seamlessly connected to the long connection between the secondary processor and the server, ensuring that the controlled device and the server are always connected, so that the user has no abnormal perception on the main control device. It can also prevent the secondary processor from being directly squeezed out by the main processor, triggering the reconnection function of the secondary processor, and causing the secondary processor to compete for the connection to the server.
[0084] (3) Reduce write losses to the secondary processor and extend its service life. Specifically, due to the lower specifications of the secondary processor, the number of writes to the NVM (e.g., flash memory) integrated in the secondary processor is limited. Therefore, before each information synchronization, the controlled device needs to query the information in the secondary processor through the main processor to see if it is consistent with the information to be synchronized. Only if there is an inconsistency will the information be written to the secondary processor.
[0085] Next, we will introduce the architecture diagram of the communication system 10 used in the remote control method provided in this application, as well as the product form of each device included in the communication system 10.
[0086] refer to Figure 1 , Figure 1 An exemplary schematic diagram of the architecture of a communication system 10 provided in an embodiment of this application is shown.
[0087] like Figure 1 As shown, the communication system 10 may include a master control device, a server, and a controlled device. Figure 1 The number of each device is shown as an example of only one, but the number of master control device, server and controlled device can be one or more, and this application embodiment does not limit this.
[0088] The main control device, also known as the secondary device, can be equipped with... Or other portable terminal devices with different operating systems. The product forms of the main control device include, but are not limited to: mobile phones, tablets, desktop computers, laptops, handheld computers, notebook computers, ultra-mobile personal computers (UMPCs), netbooks, personal digital assistants (PDAs), wearable devices, in-vehicle devices, or other types of electronic devices.
[0089] In this embodiment, the main control device can establish a communication connection with the server and perform data communication based on this communication connection. Specifically, this includes the following:
[0090] (1) After the master control device detects the remote control operation input by the user, it can send instructions for remote control of the controlled device (such as power on, sleep wake-up, hibernation wake-up, restart, and power off instructions) to the server based on the communication connection.
[0091] (2) The master control device can also receive the status information of the controlled device (such as power off, hibernation, sleep, fault, power, etc.) forwarded by the server based on the communication connection.
[0092] The controlled device, also known as the first device, can be equipped with... Or other portable terminal devices with different operating systems. The product forms of the controlled devices include, but are not limited to: tablet computers, desktop computers, laptop computers, notebook computers, super mobile personal computers, netbooks, as well as augmented reality (AR) devices, virtual reality (VR) devices, artificial intelligence (AI) devices, wearable devices, in-vehicle devices, smart home devices and / or smart city devices, etc.
[0093] In this embodiment, the controlled device can establish a communication connection with the server through a main processor / secondary processor, and perform data communication based on this communication connection. Specifically, this includes the following:
[0094] (1) The controlled device can establish a long connection with the server through the secondary processor, and the controlled device can also receive remote control commands or send the status of the controlled device based on the long connection.
[0095] Specifically, when the controlled device is powered off, in hibernation, in sleep mode, or powered on but malfunctioning, the main processor of the controlled device is in a non-working state, while the secondary processor and the EC (Engineer Control) are in a working state. Therefore, the controlled device can establish a long-lived connection with the server through the secondary processor and conduct data communication based on this connection. For example, the secondary processor can receive remote control commands (such as power-on, wake-up from sleep, wake-up from hibernation, and restart commands) forwarded by the server through this long-lived connection, and then instruct the EC to start the processor based on the remote control command to execute the corresponding task. As another example, the controlled device can also send its status information (such as power-off, hibernation, sleep mode, malfunction, and battery level) to the server through the long-lived connection established between the secondary processor and the server.
[0096] (2) Figure 1As not shown, the controlled device can establish a long connection with the server through a secondary processor, and the controlled device can also receive remote control commands or send the status of the controlled device based on the long connection.
[0097] Specifically, when the controlled device is powered on and functioning properly, its main processor is operational. Therefore, the controlled device can establish a communication connection with the server through the main processor and conduct data communication based on this persistent connection. For example, the main processor can receive remote control commands (such as commands to power off, hibernate, sleep, restart, or play music, also known as third-party commands) forwarded by the server through this communication connection, and then directly execute the corresponding task based on the remote control command. As another example, the controlled device can also send its status information (such as power-on status and battery level) to the server through the communication connection established between the main processor and the server.
[0098] For details on how the controlled device establishes a communication connection with the server via the secondary processor / main processor and performs the aforementioned data communication, please refer to the following text. Figures 9-14 The method will not be described in detail here.
[0099] Furthermore, in the controlled device, the main processor and the sub-processor can be connected by a bus, the main processor and the EC can also be connected by a bus, and the sub-processor and the EC can also be connected by a bus.
[0100] Based on the bus connection between the master and slave processors, the master processor can synchronize information and send bus heartbeat messages to the slave processor. The synchronized information includes connection configuration information and device configuration information. The synchronized information is sent in the form of bus messages; therefore, connection configuration information can also be called connection configuration messages, and device configuration information can also be called device configuration messages. Connection configuration information is used by the slave processor to establish a long-lived connection with the server using the same server login information as the master processor. Device configuration information is used by the slave processor to access the network after obtaining network configuration information, and also to allow the slave processor to learn the capabilities of the controlled device, thus enabling it to parse and respond to remote control commands upon receipt.
[0101] Based on the bus connection between the main processor and the EC, the EC can control the main processor to start working based on remote control commands received from the secondary processor. Also based on the bus connection between the main processor and the EC, the EC can query the status information of the controlled device from the main processor, including but not limited to: power-on, power-off, sleep, hibernation, fault status, or battery status, etc.
[0102] Based on the bus connection between the secondary processor and the EC, the secondary processor can send corresponding remote control commands to the EC based on the remote control commands received from the server. Furthermore, based on the bus connection between the secondary processor and the EC, the EC can send the status information of the controlled device to the secondary processor, including but not limited to: power-on, power-off, sleep, hibernation, fault status, or power level status, etc.
[0103] For details on the connection relationships and data interaction between the various modules in the controlled device, please refer to the following text. Figure 3B The description of the controlled device's software architecture shown, and the subsequent discussion... Figures 9-14 The method will not be described in detail here.
[0104] The server acts as a remote relay device between the master control device and the controlled device, providing remote control services to the master control device. This includes: receiving instructions from the master control device and sending those instructions to the controlled device, enabling the controlled device to execute corresponding tasks. It also includes: receiving status information from the controlled device and sending that status information to the master control device, allowing the master control device to display the status of the controlled device to the user.
[0105] Based on the foregoing introduction of the architecture of the communication system 10, the hardware and software architecture of the various devices included in the communication system 10 will be introduced next.
[0106] refer to Figure 2 , Figure 2 A schematic diagram of the hardware architecture of the main control device is shown.
[0107] like Figure 2 The main control device may include: a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, antenna 1, antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, a sensor module 180, buttons 190, a camera 193, and a display screen 194, etc. The sensor module 180 may include a pressure sensor 180A and a touch sensor 180B.
[0108] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the main control device. In other embodiments of this application, the main control device may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
[0109] Processor 110 may include one or more processing units, such as: application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, memory, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.
[0110] The controller can serve as the nerve center and command center of the main control equipment. Based on the instruction opcode and timing signals, the controller generates operation control signals to control the fetching and execution of instructions.
[0111] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can store instructions or data that the processor 110 has just used or that are used repeatedly. If the processor 110 needs to use the instruction or data again, it can retrieve it directly from this memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.
[0112] In this embodiment of the application, the processor 110 is used to control the corresponding software and hardware modules to execute the following text. Figures 9-14 The methods described can be further explained in detail in the following text. Figures 9-14 The relevant descriptions will not be repeated here.
[0113] In some embodiments, the processor 110 may include one or more interfaces. Interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.
[0114] USB port 130 is a USB standard compliant interface, which can be a Mini USB port, Micro USB port, USB Type-C port, etc. USB port 130 can be used to connect a charger to charge the host device.
[0115] It is understood that the interface connection relationships between the modules illustrated in the embodiments of this application are merely illustrative and do not constitute a structural limitation on the main control device. In other embodiments of this application, the main control device may also employ different interface connection methods or combinations of multiple interface connection methods as described in the above embodiments.
[0116] The charging management module 140 receives charging input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 receives charging input from the wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 receives wireless charging input via the wireless charging coil of the main control device. While charging the battery 142, the charging management module 140 can also supply power to the main control device via the power management module 141.
[0117] The power management module 141 connects the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, providing power to the processor 110, internal memory 121, external memory, display screen 194, camera 193, and wireless communication module 160, etc. The power management module 141 can also monitor parameters such as battery capacity, battery cycle count, and battery health status (leakage current, impedance). In some other embodiments, the power management module 141 may also be located within the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be located in the same device.
[0118] The wireless communication function of the main control device can be implemented through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor, and baseband processor.
[0119] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in the main control device can be used to cover one or more communication frequency bands. Different antennas can also be multiplexed to improve antenna utilization. For example, antenna 1 can be multiplexed as a diversity antenna for a wireless local area network. In some other embodiments, the antennas can be used in conjunction with a tuning switch.
[0120] The mobile communication module 150 can provide solutions for wireless communication, including 2G / 3G / 4G / 5G, applied on the main control device. The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves via antenna 1, and perform filtering, amplification, and other processing on the received electromagnetic waves before transmitting them to a modem processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modem processor and convert it into electromagnetic waves for radiation via antenna 1. In some embodiments, at least some functional modules of the mobile communication module 150 may be housed in the processor 110. In some embodiments, at least some functional modules of the mobile communication module 150 and at least some modules of the processor 110 may be housed in the same device.
[0121] The modem processor may include a modulator and a demodulator. The modulator modulates the low-frequency baseband signal to be transmitted into a mid-to-high frequency signal. The demodulator demodulates the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After processing by the baseband processor, the low-frequency baseband signal is transmitted to the application processor. The application processor outputs sound signals through an audio device (not limited to speaker 170A, receiver 170B, etc.) or displays images or videos through the display screen 194. In some embodiments, the modem processor may be a separate device. In other embodiments, the modem processor may be independent of the processor 110 and may be housed in the same device as the mobile communication module 150 or other functional modules.
[0122] The wireless communication module 160 can provide solutions for wireless communication applications on the main control device, including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared (IR) technologies. The wireless communication module 160 can be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via antenna 2, demodulates and filters the electromagnetic wave signals, and sends the processed signal to processor 110. The wireless communication module 160 can also receive signals to be transmitted from processor 110, frequency modulate and amplify them, and then convert them into electromagnetic waves for radiation via antenna 2.
[0123] In some embodiments, antenna 1 of the main control device is coupled to mobile communication module 150, and antenna 2 is coupled to wireless communication module 160, enabling the main control device to communicate with networks and other devices via wireless communication technology. This wireless communication technology may include 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), BT, GNSS, WLAN, NFC, FM, and / or IR technologies, etc. The GNSS may include the Global Positioning System (GPS), the Global Navigation Satellite System (GLONASS), the BeiDou Navigation Satellite System (BDS), the Quasi-Zenith Satellite System (QZSS), and / or satellite-based augmentation systems (SBAS).
[0124] In this embodiment, the master control device can establish a communication connection with the server through the aforementioned mobile communication module 150 or wireless communication module 160, and then send remote control commands for the controlled device to the server based on the communication connection.
[0125] In this embodiment, the main control device implements display functions through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, connected to the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. The processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.
[0126] Display screen 194 is used to display images, videos, etc. Display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD). The display panel can also be manufactured using organic light-emitting diodes (OLEDs), active-matrix organic light-emitting diodes (AMOLEDs), flexible light-emitting diodes (FLEDs), miniled, microLEDs, micro-OLEDs, quantum dot light-emitting diodes (QLEDs), etc. In some embodiments, the main control device may include one or N displays 194, where N is a positive integer greater than 1.
[0127] In this embodiment of the application, the main control device can display, for example, the UI embodiment described below, on the display screen 194. Figures 6A-6D , Figure 8B , Figure 8D and Figure 8F The user interface shown here, etc., will not be described in detail here.
[0128] The main control device can achieve shooting functions through ISP, camera 193, video codec, GPU, display 194 and application processor.
[0129] The ISP (Image Signal Processor) is used to process data fed back from the camera 193. For example, when taking a picture, the shutter is opened, and light is transmitted through the lens to the camera's photosensitive element. The light signal is converted into an electrical signal, and the camera's photosensitive element transmits this electrical signal to the ISP for processing, transforming it into an image visible to the naked eye. The ISP can also perform algorithmic optimization on image noise and brightness. The ISP can also optimize parameters such as exposure and color temperature of the shooting scene. In some embodiments, the ISP can be set in the camera 193.
[0130] Camera 193 is used to capture still images or videos. An object is projected onto a photosensitive element by generating an optical image through the lens. The photosensitive element can be a charge-coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, which is then passed to an ISP for conversion into a digital image signal. The ISP outputs the digital image signal to a DSP for processing. The DSP converts the digital image signal into image signals in standard RGB, YUV, or other formats. In some embodiments, the main control device may include one or N cameras 193, where N is a positive integer greater than 1.
[0131] Digital signal processors (DSPs) are used to process digital signals. Besides digital image signals, they can also process other digital signals. For example, when the main control device is selecting a frequency point, the DSP is used to perform Fourier transforms on the frequency energy.
[0132] Video codecs are used to compress or decompress digital video. A master device can support one or more video codecs. This allows the master device to play or record videos in various encoding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, and MPEG4.
[0133] An NPU (Neural Processing Unit) is a neural network (NN) computing processor that borrows from the structure of biological neural networks, such as the transmission patterns between neurons in the human brain, to rapidly process input information and continuously learn. NPUs enable intelligent cognitive applications in control devices, such as image recognition, facial recognition, speech recognition, and text understanding.
[0134] Internal memory 121 may include one or more random access memory (RAM) and one or more non-volatile memory (NVM).
[0135] Random access memory can include static random-access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM, for example, fifth generation DDR SDRAM is generally called DDR5 SDRAM), etc.
[0136] Non-volatile memory can include disk storage devices and flash memory.
[0137] Flash memory can be classified according to its operating principle, including NOR FLASH, NAND FLASH, 3D NAND FLASH, etc.; according to the level of the storage cell, including single-level cell (SLC), multi-level cell (MLC), triple-level cell (TLC), quad-level cell (QLC), etc.; and according to the storage specification, including universal flash storage (UFS) and embedded multimedia card (eMMC), etc.
[0138] The random access memory can be directly read and written by the processor 110. It can be used to store executable programs (such as machine instructions) of the operating system or other running programs, as well as user and application data.
[0139] Non-volatile memory can also store executable programs and user and application data, and can be pre-loaded into random access memory for direct reading and writing by the processor 110.
[0140] The external memory interface 120 can be used to connect to external non-volatile memory, thereby expanding the storage capacity of the main control device. The external non-volatile memory communicates with the processor 110 through the external memory interface 120 to realize data storage functions. For example, music, video, and other files can be saved in the external non-volatile memory.
[0141] The main control device can implement audio functions, such as music playback and recording, through the audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, and application processor.
[0142] Pressure sensor 180A is used to sense pressure signals and convert them into electrical signals. In some embodiments, pressure sensor 180A can be disposed on display screen 194. There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, and capacitive pressure sensors. A capacitive pressure sensor may include at least two parallel plates with conductive material. When force is applied to pressure sensor 180A, the capacitance between the electrodes changes. The main control device determines the pressure intensity based on the change in capacitance. When a touch operation is applied to display screen 194, the main control device detects the intensity of the touch operation based on pressure sensor 180A. The main control device can also calculate the touch position based on the detection signal from pressure sensor 180A. In some embodiments, touch operations applied to the same touch position but with different touch operation intensities can correspond to different operation commands. For example: when a touch operation with an intensity less than a first pressure threshold is applied to the SMS application icon, a command to view an SMS is executed. When a touch operation with an intensity greater than or equal to the first pressure threshold is applied to the SMS application icon, a command to create a new SMS is executed.
[0143] Touch sensor 180B, also known as a "touch panel," can be located on display screen 194. The touch sensor 180B and display screen 194 together form a touchscreen, also known as a "touchscreen." Touch sensor 180B detects touch operations applied to or near it. The touch sensor can transmit the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through display screen 194. In other embodiments, touch sensor 180B may also be located on the surface of the main control device, in a different position than display screen 194.
[0144] In this application, the main control device can detect operations performed on the display screen 194 through the pressure sensor 180A and the touch sensor 180B, as described below. Figures 6A-6D The touch operations shown, etc.
[0145] Buttons 190 include a power button, volume buttons, etc. Buttons 190 can be mechanical buttons or touch-sensitive buttons. The main control device can receive button inputs and generate key signal inputs related to user settings and function control of the main control device.
[0146] refer to Figure 3A , Figure 3A A schematic diagram of the hardware architecture of the controlled device is shown.
[0147] like Figure 3A The controlled device may include: a main processor 201, a secondary processor 202, an EC 203, a communication module 204, a memory 205, a display screen 206, and a universal serial bus 207. It is understood that the hardware architecture illustrated in the embodiments of this application does not constitute a specific limitation on the controlled device. In other embodiments of this application, the controlled device may include more or fewer components than illustrated, or combine certain components, or split certain components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
[0148] The main processor 201 may include one or more processing units, such as an access point (AP), modem processor, GPU, ISP, controller, memory, video codec, DSP, baseband processor, and / or NPU. These different processing units may be independent devices or integrated into one or more processors. The controller may serve as the central nervous system and command center of the controlled device. The controller can generate operation control signals based on instruction opcodes and timing signals to control instruction fetching and execution. Typically, the main processor 201 is powered off when the controlled device is powered off, in hibernation, or in sleep mode; it is only powered on when the controlled device is powered on.
[0149] The main processor 201 may also include a cache memory. In some embodiments, this cache memory can store instructions or data that the main processor 201 has just used or is recurring. If the main processor 201 needs to use the instruction or data again, it can retrieve it directly from this cache memory. This avoids repeated accesses, reduces the waiting time of the main processor 201, and thus improves system efficiency.
[0150] The main processor 201 may include one or more interfaces. These interfaces may include an inter-integrated circuit (I2C) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, and / or a universal serial bus (USB) interface, etc.
[0151] The secondary processor 202 is a low-power microcontroller unit (MCU) supporting wireless communication. Typically, the secondary processor is always powered on, except when the controlled device's battery is depleted or damaged. The secondary processor can integrate a separate communication module 204, which allows it to access the network and establish long-term connections with other devices, such as servers, when the controlled device is not powered on.
[0152] The secondary processor 202 may also include flash memory, a non-volatile memory that retains data even when power is off. In some embodiments, this flash memory may store information synchronized from the primary processor 201 to the secondary processor 202, including but not limited to connection configuration information and device configuration information. A description of the connection configuration information and device configuration information will be provided later and will not be repeated here.
[0153] The EC 203 is essentially a microcontroller. Normally, the secondary processor is always powered on, except when the controlled device's battery is depleted or damaged.
[0154] The EC 203 also includes non-volatile memory for storing independently running software. The EC 203 is used for power management, battery management, keyboard control, touchpad control, and other functions. Specifically, the EC 203 can power the main processor 201, sub-processor 202, communication module 204, memory 205, display 206, etc. The EC 203 can also be used to monitor parameters such as battery capacity.
[0155] The communication function of the controlled device can be achieved through an antenna, a communication module 204, a modem processor, and a baseband processor.
[0156] Antennas are used to transmit and receive electromagnetic wave signals. Each antenna in the controlled device can be used to cover one or more communication frequency bands. Different antennas can also be reused to improve antenna utilization. For example, antennas can be reused as diversity antennas for a wireless local area network. In some other embodiments, antennas can be used in conjunction with tuning switches.
[0157] The modem processor may include a modulator and a demodulator. The modulator modulates a low-frequency baseband signal to be transmitted into a mid-to-high frequency signal. The demodulator demodulates the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After processing by the baseband processor, the low-frequency baseband signal is transmitted to the application processor. The application processor outputs a sound signal through an audio device or displays an image or video on a display screen. In some embodiments, the modem processor may be a separate device. In other embodiments, the modem processor may be independent of the main processor 201 and may be housed in the same device as the communication module 204 or other functional modules.
[0158] The communication module 204 may include one or more, for example, one communication module 204 may be integrated into both the main processor 201 and the sub-processor 202. The communication module 204 can provide solutions for wireless communication applications on the controlled device, including WLAN (such as Wi-Fi networks), BT, GNSS, FM, NFC, IR, etc. The communication module 204 may be one or more devices integrating at least one communication processing module. The communication module 204 receives electromagnetic waves via an antenna, demodulates and filters the electromagnetic wave signals, and sends the processed signals to the main processor 201 / sub-processor 202. The communication module 204 can also receive signals to be transmitted from the main processor 201 / sub-processor 202, frequency modulate and amplify them, and then convert them into electromagnetic waves for radiation via the antenna.
[0159] In this embodiment, the antenna and communication module 204 of the controlled device are coupled, enabling the controlled device to communicate with the server via wireless communication technology. This wireless communication technology may include WLAN, BT, GNSS, NFC, FM, and / or IR technology, etc. The GNSS may include the Global Positioning System (GPS), the Global Navigation Satellite System (GLONASS), the BeiDou Navigation Satellite System (BDS), the Quasi-Zenith Satellite System (QZSS), and / or satellite-based augmentation systems (SBAS).
[0160] The controlled device implements display functions through a GPU, display screen 206, and application processor. The GPU is a microprocessor for image processing, connected to the display screen 206 and the application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. The main processor 201 may include one or more GPUs, which execute program instructions to generate or modify display information.
[0161] The display screen 206 is used to display images, videos, etc. The display screen 206 includes a display panel. The display panel can be a liquid crystal display (LCD). The display panel can also be manufactured using organic light-emitting diodes (OLEDs), active-matrix organic light-emitting diodes (AMOLEDs), flexible light-emitting diodes (FLEDs), miniled, microLEDs, micro-OLEDs, quantum dot light-emitting diodes (QLEDs), etc. In some embodiments, the controlled device may include one or N display screens 206, where N is a positive integer greater than 1.
[0162] The memory 205 may include one or more RAMs and one or more NVMs. The RAM can be directly read and written by the main processor 201, and can be used to store executable programs (such as machine instructions) of the operating system or other running programs, as well as user and application data. The NVM can also store executable programs and user and application data, and can be pre-loaded into the random access memory for direct reading and writing by the main processor 201.
[0163] RAM can include static random-access memory (SRAM), dynamic random-access memory (DRAM), synchronous dynamic random-access memory (SDRAM), double data rate synchronous dynamic random-access memory (DDR SDRAM, for example, fifth-generation DDR SDRAM is generally called DDR5 SDRAM), etc.
[0164] NVM can include disk storage devices and flash memory. Flash memory can be classified according to its operating principle, such as NOR FLASH, NAND FLASH, and 3D NAND FLASH; according to the level of the storage cell, such as single-level cell (SLC), multi-level cell (MLC), triple-level cell (TLC), and quad-level cell (QLC); and according to the storage specification, such as universal flash storage (UFS) and embedded multimedia card (eMMC).
[0165] Bus 207 can be connected via any one or more types of interfaces, such as I2C, PCM, UART, MIPI, GPIO, and / or USB. It is understood that... Figure 3A The modules shown are connected via bus 207. Based on the bus connection between the main processor 201 and the sub-processor 202, the main processor 201 can synchronize information with the sub-processor 202. Based on the bus connection between the main processor 201 and EC 203, EC 203 can control the main processor 201 to start working based on remote control commands received from the sub-processor 202; and based on the bus connection between the main processor 201 and EC 203, EC 203 can query the status information of the controlled device from the main processor 201. Based on the bus connection between the sub-processor 202 and EC 203, the sub-processor 202 can send corresponding remote control commands to EC 203 based on remote control commands received from the server; and based on the bus connection between the sub-processor 202 and EC 203, EC 203 can send the status information of the controlled device to the sub-processor 202.
[0166] Buttons 208 include a power button, etc. Buttons 208 can be mechanical buttons or touch-sensitive buttons. The controlled device can receive button inputs and generate key signal inputs related to user settings and function control of the controlled device.
[0167] In this embodiment, both the secondary processor 202 and the main processor 201 of the controlled device can establish a communication connection with the server through the communication module 204, and perform data communication based on this communication connection. The specific implementation of establishing a communication connection between the secondary processor 202 / main processor 201 of the controlled device and the server, and performing the aforementioned data communication, can be found in the following description of the method flow, and will not be detailed here.
[0168] Figure 3B This is a schematic diagram of the software architecture of the controlled device in an embodiment of this application.
[0169] like Figure 3B As shown, the software architecture of the controlled device mainly includes a software module running on the main processor, a software module running on the secondary processor, and a software module running on the EC.
[0170] 1. Software modules running on the main processor include, but are not limited to, the following modules: bus communication management module and system manager.
[0171] The bus communication management module is used to establish bus connections with other modules, such as the bus communication management module in the configuration management module, and to send and receive bus messages based on these bus connections. These bus messages include, but are not limited to, the following types: bus heartbeat messages, connection configuration messages, device configuration messages, and commands.
[0172] The system manager is used to manage the connection between the main processor and the server. Specifically, when the controlled device is powered on, the system manager can control the main processor to establish a connection with the server, and then receive remote control commands sent by the main control device and forwarded by the server based on this connection.
[0173] 2. Software modules running on the secondary processor include, but are not limited to, the following modules: configuration management module, wake-up management module, and remote connection management module, etc.
[0174] 2-1. The configuration management module includes, but is not limited to, the following sub-modules: bus communication management module, bus heartbeat management module, connection configuration module, and device configuration management module, etc.
[0175] (1) The bus communication management module is used to establish bus connections with other modules, such as the bus communication management module in the software module running on the main processor, and to send and receive bus messages based on these bus connections, parse the bus messages, and distribute the parsed different types of messages to the corresponding modules. Specifically, it includes:
[0176] The bus communication management module will distribute the bus heartbeat message parsed from the bus message to the bus heartbeat management module;
[0177] The bus communication management module also distributes the connection configuration message parsed from the bus message to the connection configuration module. Optionally, the bus communication management module may also directly transmit instructions such as disabling the reconnection function parsed from the bus message to the login module; alternatively, the instruction to disable the reconnection function may be encapsulated in the connection configuration message and needs to be parsed by the connection configuration management module before being transmitted to the remote login management module. Alternatively, the bus communication management module may also directly transmit instructions such as releasing resources parsed from the bus message to the wake-up service management module; alternatively, the instruction to release resources may be encapsulated in the connection configuration message and needs to be parsed by the connection configuration management module before being transmitted to the wake-up service management module.
[0178] The bus communication management module will also distribute the device configuration message parsed from the bus message to the device configuration management module; optionally, the bus communication management module will also directly transmit, for example, the login server instruction (also known as the second instruction) parsed from the bus message to the wake-up service management module, or the login server instruction is encapsulated in the device configuration message and needs to be parsed by the device configuration management module before being transmitted to the wake-up service management module.
[0179] (2) The bus heartbeat management module is used to parse bus heartbeat messages and thus maintain the bus connection, specifically including:
[0180] If the bus heartbeat message is parsed from the bus heartbeat message and it is found that the bus heartbeat message was received for the first time during a power-on process, then the bus heartbeat state is considered to be heartbeat established at this time.
[0181] If the bus heartbeat message is parsed from the bus heartbeat message and it is found that no bus heartbeat message was received during a power-on process and after the heartbeat was established, then the bus heartbeat status at this time is considered to be heartbeat loss;
[0182] If a bus heartbeat message is parsed from the bus heartbeat message and it is found that a bus heartbeat message was received during a power-on process and after the heartbeat was lost, then the bus heartbeat state at this time is considered to be heartbeat recovery.
[0183] Furthermore, the bus heartbeat management module also transmits the heartbeat status to the wake-up management module, so that the wake-up management module can determine whether to start the remote connection management module based on the heartbeat status, in order to establish / disconnect a long connection with the server.
[0184] (3) The connection configuration module is used to parse connection configuration messages. Connection configuration messages include server login information, and may also include instructions to disable reconnection, instructions to release resources, etc. Specifically, they include:
[0185] If the server login information is parsed from the connection configuration message, the connection configuration module calls the interface of the remote connection management module to synchronize it to the network management in the remote connection management module for storage;
[0186] If a command to disable the reconnection function is parsed from the connection configuration message, the connection configuration module notifies the remote login module to disable the reconnection function. Optionally, the command to disable the reconnection function can be sent directly from the bus communication management module to the remote login module, without needing to be parsed and forwarded from the connection configuration message by the connection configuration management module.
[0187] If instructions to release resources are parsed from the connection configuration message, the connection configuration module calls the wake-up management module's interface to notify the remote login module to release temporary data resources. Additionally, the wake-up service management module will disconnect the connected network. Optionally, instructions to release resources can be sent directly from the bus communication management module to the wake-up management module, without needing to be parsed and forwarded from the connection configuration message by the connection configuration management module.
[0188] (4) The device configuration management module is used to parse device configuration messages, which include, but are not limited to: device capability description file (also known as profile file), network configuration information (including network identifier and corresponding primary password, such as WiFi account and corresponding password), device identifier (such as serial number (SN), universally unique identifier (UUID)). Or it may also include: instructions for logging into the server, instructions for restoring factory settings, etc.
[0189] If a Profile file is parsed from the device configuration message, the device configuration management module stores the Profile file.
[0190] If network configuration information is parsed from the device configuration message, the device configuration management module stores the network configuration information.
[0191] If the device identifier is parsed from the device configuration message, the device configuration management module stores the device identifier;
[0192] If the login server command is parsed from the device configuration message, the wake-up management module's interface is invoked to pass it to the wake-up service management module. This causes the wake-up service management module to initiate the login module within the remote connection management module to establish a long-lived connection with the server. Optionally, the login server command can be directly sent from the bus communication management module to the wake-up service management module, without the device configuration management module needing to parse the device configuration message and forward it to the wake-up service management module.
[0193] 2-2. The wake-up management module running on the secondary processor includes, but is not limited to, the following sub-modules: wake-up service management module, EC control module, etc.
[0194] (1) The wake-up service management module can be used for:
[0195] The system receives a login server instruction from the bus management module or device configuration management module. Based on this instruction, it obtains network configuration information from the device configuration management module to connect to the network, and obtains a Profile file from the device configuration management module and passes it to the login module in the remote connection management module. This enables the login module in the remote connection management module to obtain server login information from the networking module, establishes a long connection with the server based on the server login information, and subscribes to remote control services from the server based on the Profile file.
[0196] The system receives heartbeat status data from the bus heartbeat management module and manages the long-term connection between the remote connection management module and the server based on this heartbeat status (e.g., establishing and closing long-term connections). Specifically, when the controlled device abnormally shuts down, goes into hibernation, sleeps, or malfunctions, causing the main processor to fail to send a login message to the secondary processor, the heartbeat status is "heartbeat lost." In this case, the wake-up service management module retrieves network configuration information from the device configuration management module to connect to the network, and retrieves a profile file from the device configuration management module and transmits it to the login module in the remote connection management module. This enables the login module in the remote connection management module to retrieve server login information from the network module, establishes a long-term connection with the server based on this login information, and subscribes to remote control services from the server based on the profile file. When the controlled device powers on, wakes from hibernation, wakes from sleep, or restarts, the heartbeat status is "heartbeat established / heartbeat restored." In this case, the wake-up service management module controls the login module in the remote connection management module to disconnect the long-term connection from the server.
[0197] It receives instructions from the bus management module or connection configuration module to release resources and notifies the login module in the remote connection management module to release temporary data resources. In addition, waking up the service management module will disconnect the connected network.
[0198] It receives remote control commands (such as power on, wake up from hibernation, wake up from sleep, restart, etc.) from the cloud service connection management module, and controls the device software modules (such as the control module) running on the EC to execute corresponding tasks through the EC control module.
[0199] (2) The EC control module can be used to control the main chip to start up in order to achieve power-on, hibernation wake-up, sleep wake-up, restart, etc., according to the instructions such as power-on, hibernation wake-up, sleep wake-up, restart, etc. transmitted by the wake-up service management module.
[0200] 2-3. The remote connection management module running on the secondary processor includes, but is not limited to, the following sub-modules: network management module, login module, and device control module, etc.
[0201] (1) The network management module is used to receive and store the server login information sent by the connection configuration module.
[0202] (2) The login module receives the instruction to enable remote connection from the wake-up service management module, and obtains server login information from the network management module based on the instruction to log in to the server. The login module is also used to receive the instruction to disable the reconnection function directly from the bus management module or through the connection configuration module, and to disable the reconnection function. The login module is also used to receive the instruction to release resources directly from the bus management module or through the connection configuration module and the wake-up service management module, and to clear temporary data in RAM.
[0203] (3) The device control module is used to receive remote control commands sent by the server and pass them to the wake-up service management module through callback to control the EC's control module to execute the task corresponding to the command.
[0204] 3. The software modules running on the EC include, but are not limited to, the following sub-modules: Control Module. This control module is used to receive control commands sent by the EC control module in the subprocessor, and then control the startup of the main processor's software modules.
[0205] refer to Figure 4 , Figure 4 This is a schematic diagram of the hardware architecture of a server provided in an embodiment of this application.
[0206] like Figure 4 As shown, the server may include: one or more processors 301, memory 302, communication interface 303, transmitter 305, receiver 306, coupler 307, and antenna 308. These components can be connected via bus 304 or other means. Figure 4 Taking a connection via bus 304 as an example. Where:
[0207] The processor 301 can be used to read and execute computer-readable instructions. Specifically, the processor 301 can be used to call a program stored in the memory 302, such as the method implemented on the server side of the method for forwarding remote control instructions sent by the master device to the controlled device according to the embodiments of this application, and execute the instructions contained in the program.
[0208] The memory 302 is coupled to the processor 301 and is used to store various software programs and / or multiple sets of instructions. Specifically, the memory 302 may include high-speed random access memory and may also include non-volatile memory, such as one or more disk storage devices, flash memory devices, or other non-volatile solid-state storage devices.
[0209] The memory 302 can store an operating system (hereinafter referred to as the system), such as uCOS, VxWorks, RTLinux, and other embedded operating systems. The memory 302 can also store a network communication program, which can be used to communicate with the electronic device 100, etc. The memory 302 can also store device information and login information of the controlled device.
[0210] The communication interface 303 can be used by the server to communicate with other communication devices, such as master and slave devices. Specifically, the communication interface 303 can be a 3G communication interface, a Long Term Evolution (LTE) (4G) communication interface, a 5G communication interface, a WLAN communication interface, a WAN communication interface, etc. Not limited to wireless communication interfaces, the server can also be configured with a wired communication interface 303 to support wired communication.
[0211] In some embodiments of this application, transmitter 305 and receiver 306 can be considered as a wireless modem. Transmitter 305 can be used to transmit signals output by processor 301. Receiver 306 can be used to receive signals. In a server, the number of transmitters 305 and receivers 306 can be one or more. Antenna 308 can be used to convert electromagnetic energy in a transmission line into electromagnetic waves in free space, or to convert electromagnetic waves in free space into electromagnetic energy in a transmission line. Coupler 307 can be used to split mobile communication signals into multiple paths and distribute them to multiple receivers 306. Understandably, the antenna 308 of the network device can be implemented as a massive MIMO (Massively Multi-Size Antenna Array).
[0212] Based on the above description of embodiments of communication systems, electronic devices, and servers involved in this application, the remote control method provided by this application will be described next in conjunction with UI embodiments.
[0213] Figures 5A-5D An example diagram of the operation interface for a set of controlled devices during normal shutdown is shown.
[0214] like Figure 5A As shown, Figure 5A The interface shown is any interface displayed when the controlled device is powered on, and it displays a start icon 512. In addition, the controlled device also integrates a physical power button 511.
[0215] The controlled device can receive operations performed on the start icon 512 (e.g., a user clicking the start icon 512 with the cursor). In response to this operation, the controlled device displays power options 513, see details. Figure 5B The content shown.
[0216] like Figure 5B As shown, the controlled device displays power option 513.
[0217] The controlled device can receive operations applied to power option 513 (e.g., user-controlled cursor clicks on power option 513). In response to this operation, the controlled device expands and displays multiple sub-options, see details below. Figure 5C The content shown.
[0218] like Figure 5C As shown, the controlled device displays multiple sub-options included in power option 513, such as power off option 514, sleep option, and restart option, etc.
[0219] The controlled device can receive operations applied to the power-off option 514 (e.g., a user clicking the cursor on the power-off option 514). In response to this operation, the controlled device will power off, specifically by cutting off the power to most of the hardware except for the subprocessor and EC, such as disconnecting the power to the main processor, display screen, etc.
[0220] like Figure 5D As shown, after the controlled device is powered off, the display screen loses power and displays no content. Furthermore, after the controlled device is powered off, both the secondary processor and the EC (Electronic Control Unit) of the controlled device are powered on and operational. The secondary processor can establish a persistent connection with the server to receive remote control commands from the primary control device forwarded by the server. Additionally, the secondary processor will enable a reconnection function to automatically request a new persistent connection from the server in the event of an abnormal disconnection.
[0221] Understandable Figures 5A-5D This is merely an example of one method of powering off. Alternatively, the controlled device can also be powered off by directly operating the power button 511, or by cutting off the power supply to cause the controlled device to power off abnormally, or by remotely controlling the controlled device to power off through the main control device, etc. This application embodiment does not limit the time of powering off the controlled device, and will not be described in detail here.
[0222] Figures 6A-6G An example is shown in the schematic diagram of a set of operation interfaces for remotely controlling the power-on of the controlled device through the master control device.
[0223] like Figure 6A As shown, Figure 6A The desktop of the main control device includes the settings application icon 611, and may also include other application icons, such as smart living application icons, etc.
[0224] The main control device can receive operations applied to the settings application icon 611. In response to these operations, the main control device displays the settings details page. See details below. Figure 6B The content shown.
[0225] like Figure 6BAs shown, Figure 6B The main control device's settings details page includes several sub-setting options, such as more connection options 612.
[0226] The master device can receive operations applied to the more connectivity option 612. In response to these operations, the master device displays the more connectivity details page. See details below. Figure 6C The content shown.
[0227] like Figure 6C As shown, Figure 6C For more connection details, there is a page that includes various connection sub-options, such as option 613 to connect to my PC.
[0228] The host device can receive operations on option 613 applied to the PC connected to it. In response to these operations, the host device displays the PC to which it is connected. See details. Figure 6D The content shown.
[0229] like Figure 6D As shown, the main control device displays a list of 614 pre-added controlled devices, such as Xiao Li's MagicBook 14, Xiao Li's MagicBook 16, and Xiao Li's watch. There are several ways to add controlled devices, such as scanning the device's QR code to obtain its identifier, or obtaining the identifier via Bluetooth, Wi-Fi, or other methods.
[0230] The main control device can receive the action of Figure 6D The operation shown is on Xiao Li's MagicBook 14. In response to this operation, the main control device displays the remote control interface for Xiao Li's MagicBook 14. See details. Figure 6E The content shown. Among them, Xiao Li's MagicBook 14 is the controlled device described in this application, and is also the aforementioned... Figures 5A-5D The controlled device is described.
[0231] like Figure 6E As shown, the main control device displays a remote control interface for Xiao Li's MagicBook 14. This interface displays the current status of Xiao Li's MagicBook 14, such as being in a powered-off state, as well as the power-on icon 615, and other options, such as hibernation, sleep, restart, and more.
[0232] The main control device can receive the action of Figure 6EThe operation shown on the power-on icon 615 triggers a remote power-on command sent by the main control device to the controlled device "Xiao Li's MagicBook 14" via the server, thereby controlling the controlled device to power on.
[0233] like Figure 6F As shown, the controlled device receives a remote power-on command forwarded by the master device through the server based on the connection between the secondary processor and the server. Then, the secondary processor of the controlled device starts the master processor through EC, thereby starting the controlled device.
[0234] like Figure 6G As shown, after the controlled device starts up, it is in a powered-on state, displaying its desktop. Furthermore, after the controlled device powers on, its main processor instructs the secondary processor to disable the reconnection function and then establish a connection with the server. This automatically disconnects the long-term connection previously established between the secondary processor and the server. The controlled device can also receive remote control commands forwarded by the server from the main control device based on the connection between the main and secondary processors.
[0235] Figures 7A-7C An example diagram shows a set of operation interfaces for controlling the power-on of the controlled device through local operation.
[0236] like Figure 7A As shown, Figure 7A The interface shows the controlled device in the powered-off state.
[0237] The controlled device can receive the operation applied to the power button 511. The EC of the specific controlled device can detect the operation and wake up the main processor in response to the operation, that is, control the main processor to power on to start working.
[0238] like Figure 7B As shown, Figure 7B The interface shows the controlled device starting up.
[0239] like Figure 7C As shown, Figure 7C The interface shows the controlled device after startup, i.e., after switching to the power-on state. Furthermore, after the controlled device powers on, the main processor of the controlled device instructs the secondary processor to disable the reconnection function and then establish a connection with the server. This automatically disconnects the long connection previously established between the secondary processor and the server. The controlled device can also receive remote control commands from the main control device forwarded by the server based on the connection between the main processor and the secondary processor.
[0240] Figures 8A-8F An exemplary diagram illustrates a scenario where the secondary processor of a group of controlled devices loses power and then regains power.
[0241] like Figure 8A As shown, Figure 8AThis diagram illustrates a controlled device that is powered off and establishes a long connection with the server via a secondary processor. (The diagram shows the controlled device in a state where...) Figure 8A When the indicated state is reached, the main control device can display... Figure 8B The remote control interface shown.
[0242] like Figure 8B As shown, Figure 8B This shows the remote control interface displayed by the master control device when the controlled device is powered off and a long connection is established with the server via the secondary processor. The content displayed on this remote control interface is the same as described above. Figure 6E The content shown is the same, and users can remotely control the controlled device to turn on by operating on the power-on icon 615 in the remote control interface.
[0243] like Figure 8C As shown, Figure 8C This diagram illustrates the controlled device being powered off, and the secondary processor losing power, thus breaking the long-term connection with the server. The controlled device is in... Figure 8C When the indicated state is reached, the main control device can display... Figure 8D The remote control interface shown.
[0244] like Figure 8D As shown, Figure 8D This diagram shows the remote control interface displayed by the master device when the controlled device is powered off and the secondary processor is powered off. The remote control interface displays a prompt message 811 indicating that the controlled device is offline. This prompt message 811 may include, for example, "PC offline, remote control is temporarily unavailable." Optionally, in one possible implementation, the master device may also make all remote control-related icons and controls inoperable, such as displaying them in gray. Figure 8D Not shown.
[0245] like Figure 8E As shown, Figure 8E This diagram illustrates the process of the controlled device being powered off, and the secondary processor being powered off and then powered back on, thus re-establishing the long-term connection with the server. The controlled device is in... Figure 8E When the indicated state is reached, the main control device can display... Figure 8F The remote control interface shown.
[0246] like Figure 8F As shown, Figure 8FThis diagram illustrates the remote control interface displayed by the master control device when the controlled device is powered off and the secondary processor is powered off and then powered on again, thus re-establishing the long-term connection with the server. The remote control interface displays a notification message 812 indicating that the controlled device is online, which may include, for example, "PC online, remote control available." Optionally, in one possible implementation, the master control device may also restore all remote control-related icons and controls to an operable state.
[0247] This is because, after the controlled device established a long connection with the server, the controlled device enabled the reconnection function. Therefore, if the secondary processor of the controlled device suddenly loses power and then is restored, the secondary processor of the controlled device can automatically trigger a new request to establish a long connection with the server, thereby restoring the long connection.
[0248] In this application's embodiments, the UI embodiments described above only illustrate the remote control function provided through the settings application of the main control device. In addition, the remote control function can also be implemented through other system-level applications installed on the main control device, such as Smart Life, or other third-party applications. Regardless of the application used to provide the remote control function, the specific implementation method can be the remote control method provided in this application; please refer to the description of the method embodiments below for details.
[0249] refer to Figure 9 , Figure 9 An example is shown of a remote control method provided in this application.
[0250] like Figure 9 As shown, the method includes the following steps:
[0251] Optional operation S61: When the controlled device is powered on, the main processor of the controlled device synchronizes information with the secondary processor.
[0252] Specifically, after each power-on of the controlled device, both the main processor and the slave processor are powered on and in working condition. The main processor synchronizes information with the slave processor based on a pre-established bus connection. For details on the specific implementation of this synchronization, please refer to the following text. Figures 10-11 A detailed description of the interaction process.
[0253] Specifically, the information synchronized from the main processor to the secondary processor can be in the form of bus messages. These bus messages include, but are not limited to, the following types: bus heartbeat messages, connection configuration messages (including the server login information described earlier), and device configuration messages (including the device identifier, network configuration information, and profile file described earlier). Optionally, some instructions sent by the main processor can also be sent to the secondary processor in the form of bus messages. For example, instructions to log in to the server or restore factory settings can be encapsulated in device configuration messages; similarly, instructions to disable reconnection or release resources can be encapsulated in device configuration messages.
[0254] S61 is an optional operation. In some possible implementations, the controlled device can pre-store the information that needs to be synchronized in the main processor and the sub-processor, so that the main processor does not need to synchronize with the sub-processor.
[0255] S62: When the controlled device is powered off, hibernating, sleeping, or powered on but malfunctioning, the controlled device establishes a first connection with the server through the secondary processor and enables the reconnection function of the secondary processor.
[0256] In one possible implementation, after the main processor of the controlled device receives the input for power off, hibernation, or sleep, the main processor first sends a login server instruction to the secondary processor, which then uses this instruction to access the network based on the network configuration information in the synchronization information. The secondary processor then establishes a first connection with the server based on the server login information in the synchronization information (i.e., the long connection described above). Only then does the main processor power off and stop working, thereby causing the controlled device to enter the power off, hibernation, or sleep state.
[0257] In another possible implementation, after the main processor receives the input to power off, hibernate, or sleep, if the main processor stops working before it has sent the login server instruction to the slave processor, the main processor cannot periodically send heartbeat messages to the slave processor based on the bus connection. The slave processor can then determine that the heartbeat with the main processor has been lost, and thus the slave processor can access the network according to the network configuration information in the synchronization information, and then establish a first connection with the server according to the server login information in the synchronization information.
[0258] In another possible implementation, when the controlled device is powered on but malfunctioning, the main processor is powered on but cannot work properly. Therefore, the main processor cannot periodically send heartbeat messages to the secondary processor based on the bus connection. The secondary processor can then determine that the heartbeat between it and the main processor has been lost. This allows the secondary processor to access the network according to the network configuration information in the synchronization information, and then establish a first connection with the server according to the server login information in the synchronization information.
[0259] Furthermore, the secondary processor of the controlled device is pre-configured with a reconnection function. This means that once a connection is established between the secondary processor and the server, the secondary processor automatically enables the reconnection function by default. The reconnection function includes the ability for the secondary processor to automatically re-request the establishment of the long-term connection with the server after the long-term connection is lost. For example, if the secondary processor suddenly disconnects, causing the long-term connection with the server to break, it will automatically trigger a re-request to establish the long-term connection with the server after power is restored.
[0260] When the controlled device is in the aforementioned power-off, hibernation, sleep, or power-on but faulty state, if the controlled device receives power-on, hibernation wake-up, sleep wake-up, or restart input, the controlled device will establish a second connection with the server through the main processor and disconnect the first connection between the secondary processor and the server.
[0261] The following sections S63-1, S64-1, and S65-1 describe the specific implementation of how, after triggering the controlled device to power on, wake from hibernation, wake from sleep, or restart via local operation, the controlled device establishes a remote connection with the server through the main processor.
[0262] S63-1, The controlled device detects a power-on, sleep wake-up, sleep wake-up, or restart operation that is performed locally.
[0263] Specifically, the power-on, sleep wake-up, sleep wake-up, or restart operations performed locally can be operations performed on physical buttons or operations performed on virtual controls on the display screen. The above operations can be directly received by the main processor of the controlled device, or detected by the EC of the controlled device and then transmitted to the main processor. This application embodiment does not limit this.
[0264] S64-1: The controlled device wakes up the main processor directly or through EC, then controls the sub-processor to disable the reconnection function through the main processor, and establishes a second connection with the server through the main processor.
[0265] Specifically, when the controlled device's main processor directly receives a local power-on, sleep-wake, sleep-wake, or restart operation, the controlled device directly starts the processor. When the controlled device detects a local power-on, sleep-wake, sleep-wake, or restart operation through the EC (Engineer Control), the controlled device starts the main processor through the EC. Starting the main processor includes powering on the main processor to enable it to work; for example, the controlled device may use the main processor to control the secondary processor to disable the reconnection function, and establish a second connection with the server after connecting to the network through the main processor. In addition, starting the main processor also performs other initialization operations to switch the controlled device to the state after power-on, sleep-wake, sleep-wake, or restart.
[0266] Optionally, when the main processor and the secondary processor use the same server login information (account), the first connection between the secondary processor and the server will be automatically disconnected when the main processor establishes a second connection with the server.
[0267] S65-1, the controlled device receives and responds to the remote control commands forwarded by the master control device from the server based on the second connection.
[0268] Specifically, after the controlled device establishes a second connection with the server through the main processor, the controlled device can receive remote control commands (such as commands to shut down, hibernate or sleep, or play music, etc.) sent by the main control device and forwarded by the server based on the second connection, thereby enabling the main processor to execute corresponding tasks according to the remote control commands.
[0269] The following sections S63-2, S64-2, and S65-2 describe the specific implementation of establishing a remote connection between the controlled device and the server through the main processor after triggering the controlled device to power on, wake from hibernation, wake from sleep, or restart via remote control commands.
[0270] S63-2, the controlled device receives a power-on, hibernation wake-up, sleep wake-up, or restart command based on the first connection.
[0271] Specifically, after the controlled device establishes a first connection with the server through the sub-processor as described in S62, the sub-processor of the controlled device can receive instructions from the master control device forwarded by the server based on the first connection. These instructions may include power-on, wake-up from hibernation, wake-up from sleep, or restart instructions. The aforementioned instructions received by the sub-processor of the controlled device based on the first connection can also be referred to as the first instruction.
[0272] In S64-2, the controlled device controls the EC through the secondary processor to start the main processor, then controls the secondary processor to disable the reconnection function through the main processor, and establishes a second connection with the server through the main processor.
[0273] Specifically, after the secondary processor of the controlled device receives a power-on, hibernation / wake-up, sleep / wake-up, or restart command, it can instruct the EC to start the main processor based on the command. Starting the main processor includes powering on the main processor to enable it to start working. For example, the controlled device can use the main processor to control the secondary processor to disable the reconnection function, and then use the main processor to connect to the network and establish a second connection with the server. In addition, starting the main processor will also perform other initialization operations to switch the controlled device to the state after power-on, hibernation / wake-up, sleep / wake-up, or restart.
[0274] S65-2, the controlled device receives and responds to the remote control commands forwarded by the master control device from the server based on the second connection.
[0275] Specifically, after the controlled device establishes a second connection with the server through the main processor, the controlled device can receive remote control commands (such as commands to shut down, hibernate or sleep, or play music, etc.) sent by the main control device and forwarded by the server based on the second connection, thereby enabling the main processor to execute corresponding tasks according to the remote control commands.
[0276] It is evident that implementing the above... Figure 9 The method shown can bring about the following technical effects:
[0277] First, it enables more remote control scenarios. That is, when the controlled device is powered off, in sleep or hibernation mode, or powered on but malfunctioning, the controlled device can establish a long connection with the server through the secondary processor, and receive and respond to remote control commands from the master device forwarded by the server based on this long connection; when the controlled device is powered on, it can establish a connection with the server through the main processor, and receive and respond to remote control commands from the master device forwarded by the server based on this connection.
[0278] Secondly, seamless connection to the server via primary and secondary processors ensures the stability of remote connections. Specifically:
[0279] On the one hand, when the controlled device is powered off, in hibernation, in sleep mode, or powered on but malfunctioning, the secondary processor of the controlled device automatically activates the reconnection function. This allows the secondary processor to re-request the establishment of a long-term connection with the server when it is abnormally disconnected, thereby ensuring the stability of the long-term connection between the secondary processor and the server. For example, if the secondary processor is powered off and then powered on again, the power outage will cause the long-term connection to be broken, but after power is restored, the secondary processor can automatically request the establishment of a long-term connection with the server.
[0280] On the other hand, when the controlled device is powered on, the main processor of the controlled device will first notify the secondary processor to disable the reconnection function, and then establish a communication connection between the main processor and the server to automatically disconnect the connection between the secondary processor and the server. In this way, the communication connection between the main processor and the server is seamlessly connected to the long connection between the secondary processor and the server, ensuring that the controlled device and the server are always connected, so that the user has no abnormal perception on the main control device. It can also prevent the secondary processor from being directly squeezed out by the main processor, triggering the reconnection function of the secondary processor, and causing the secondary processor to compete for the connection to the server.
[0281] Next, combined Figure 10 This paper will introduce the interaction process between various devices involved in a remote control method provided in this application.
[0282] like Figure 10As shown, the communication system involved in this remote control method includes: a master control device, a server, and a controlled device, wherein the controlled device includes a master processor, a slave processor, and an EC. Figure 10 The example shown is based solely on the EC as a separate chip in the controlled device. In other feasible implementations, the EC may also be integrated into the main processor, and this application does not impose any restrictions on this.
[0283] Figure 10 The interaction flow between the devices shown includes the following:
[0284] Phase 1 (S111-S112): After each power-on, the main processor and the secondary processor synchronize information based on the bus connection of the controlled device.
[0285] S111, the main processor and the secondary processor of the controlled device establish a bus connection.
[0286] Specifically, each time the controlled device is powered on, both the main processor and the secondary processor of the controlled device are powered on to start working. The work performed by the main processor includes, but is not limited to, establishing a bus connection between the main processor and the secondary processor.
[0287] This application does not limit the type of bus connection. The type of bus connection can be any one or more of the following: USB, PCI, SPI, I2C, PCM, UART, MIPI, GPIO, etc.
[0288] S112, the master processor of the controlled device sends bus messages to the slave processor, such as bus heartbeat messages, connection configuration messages and device configuration messages.
[0289] Specifically, after the main processor and the secondary processor of the controlled device establish a bus connection, the main processor sends bus messages to the secondary processor based on the bus connection.
[0290] Bus messages include, but are not limited to, the following types of messages: bus heartbeat messages, connection configuration messages, device configuration messages, and commands. For a detailed description of the specific functions of each type of message, please refer to the preceding text; alternatively, the following descriptions will not be repeated here.
[0291] The following describes the process by which the controlled device establishes a remote connection with the server to achieve remote functionality after the controlled device is powered off, hibernating, or sleeping.
[0292] Considering the possibility of malfunctions in the controlled equipment, this application provides an interactive process for implementing remote control functions under abnormal shutdown, hibernation, and sleep conditions (see stage 2-1), and also provides an interactive process for implementing remote control functions under normal shutdown, hibernation, and sleep conditions (see stage 2-2).
[0293] Phase 2-1 (S121-S125): After the controlled device shuts down abnormally, goes into hibernation or sleep mode, it establishes the first connection with the server through the secondary processor to realize the remote control function.
[0294] S121, the slave processor of the controlled device timed out and did not receive the bus heartbeat message.
[0295] Specifically, after receiving the bus heartbeat message described in S112, the secondary processor of the controlled device can parse the heartbeat status (including heartbeat establishment, heartbeat recovery, and heartbeat loss). If the secondary processor of the controlled device does not receive the bus heartbeat message within a timeout, it is confirmed that the heartbeat status is heartbeat loss. Therefore, it can be considered that the controlled device is in an abnormal state, causing the main processor to be unable to work normally and unable to send bus heartbeat messages to the secondary processor periodically.
[0296] Among them, the abnormal state of the controlled device can be: the controlled device is abnormally shut down, hibernating or sleeping, causing the main processor to suddenly lose power and stop working, or the controlled device is in the power-on state but has a fault, causing the main processor to be powered on but unable to work normally.
[0297] S122, the secondary processor of the controlled device accesses the network based on the network configuration information in the device configuration message.
[0298] Specifically, after receiving the device configuration message described in S112, the secondary processor of the controlled device can parse the network configuration information (such as WiFi account and password) from it, and then the secondary processor can access the network based on the network configuration information.
[0299] S123, the secondary processor of the controlled device requests the establishment of the first connection from the server based on the server login information in the connection configuration message.
[0300] Specifically, after receiving the connection configuration message described in S112, the secondary processor of the controlled device can parse the server login information (such as the login account and corresponding password, also known as the second password) from it, and then request to establish a first connection with the server based on the server login information. In addition, when requesting to establish a first connection with the server, the secondary processor of the controlled device will also carry the identifier of the controlled device, which can be obtained in advance from the device configuration message.
[0301] S124, the server sends a message to the secondary processor of the controlled device indicating that the first connection has been successfully established.
[0302] Specifically, after the server receives the request to establish the first connection from the slave processor of the controlled device, it can verify the login account and password. If the verification is successful, the server replies to the slave processor with an indication that the first connection has been successfully established. The server also stores the identifier of the controlled device, which is used to subsequently send remote control commands sent by the master device to the corresponding controlled device based on the identifier of the controlled device.
[0303] S125, the secondary processor of the controlled device enables the reconnection function.
[0304] Specifically, the secondary processor of the controlled device is pre-configured with a reconnection function. After the secondary processor confirms the establishment of the first connection with the server, the reconnection function can be automatically enabled by default. The reconnection function includes: after the secondary processor disconnects from the server, it can automatically request to re-establish the long-term connection with the server. For example, if the secondary processor suddenly disconnects, causing the long-term connection with the server to be lost, it will automatically trigger a re-request to establish the long-term connection with the server after power is restored.
[0305] Phase 2-2 (S131-S136): After the controlled device is normally powered off, hibernated, or put to sleep, it establishes the first connection with the server through the secondary processor to realize the remote control function.
[0306] S131, the main processor of the controlled device receives an input indicating power off, hibernation, or sleep.
[0307] Specifically, when the controlled device is powered on, the main processor of the controlled device can receive input for power off, hibernation, or sleep.
[0308] The aforementioned main processor receiving input for power off, hibernation, or sleep can be triggered by an operation on a physical button of the controlled device, or by an operation on a virtual control displayed on the controlled device. This application embodiment does not limit this.
[0309] The aforementioned input can be directly detected by the main processor of the controlled device, or detected by the EC of the controlled device and transmitted to the main processor. This application embodiment does not limit this.
[0310] S132, the main processor of the controlled device notifies the secondary processor to log in to the server.
[0311] Specifically, after the main processor of the controlled device receives the aforementioned power off, hibernation, or sleep input, it needs to send an instruction to the secondary processor before powering off and stopping work, instructing the secondary processor to log in to the server. Only after the secondary processor logs in to the server will the main processor power off and stop work, causing the controlled device to enter a power off, hibernation, or sleep state.
[0312] The instructions for logging into the server can be sent in the form of bus messages, which can be encapsulated in device configuration messages.
[0313] S133-S136 correspond one-to-one with S122-S125 in stage 2-1. Please refer to the previous description for details, which will not be repeated here.
[0314] The following section describes how to wake up a controlled device when it is powered off, in hibernation, or in sleep mode, and how to establish a remote connection with the server after the controlled device is woken up to achieve the interactive process of remote functions.
[0315] Considering that the methods for waking up the controlled device include remote wake-up and local wake-up, this application provides an interactive process for achieving remote control through remote wake-up (see stage 3-1), and also provides an interactive process for achieving remote control through local wake-up (see stage 3-2).
[0316] Phase 3-1 (S141-S154): After the controlled device is remotely powered on, wakes up from hibernation or sleep, the controlled device disconnects the first connection and establishes a second connection with the server through the main processor to realize the remote control function.
[0317] S141, the main control device sends power-on, hibernation wake-up, sleep wake-up or restart commands to the server.
[0318] Specifically, the master control device can pre-login to the server and add the controlled devices to the server to subscribe to the service of remotely controlling the controlled devices. Then, based on user actions, the master control device can send commands to the server to power on, wake from hibernation, wake from sleep, or restart the controlled devices.
[0319] S142, the server sends power-on, sleep-wake, sleep-wake, or restart commands to the secondary processor of the controlled device based on the first connection.
[0320] Specifically, after receiving a remote control command for the controlled device from the master device, the server can send power-on, sleep-wake, sleep-wake, or restart commands to the secondary processor.
[0321] S143, the secondary processor of the controlled device identifies instructions based on the Profile file in the device configuration message.
[0322] Specifically, after receiving the device configuration message described in S112, the secondary processor of the controlled device can parse out the Profile file from it and identify the meaning of the instruction based on the Profile file.
[0323] The Profile file describes the capabilities of the controlled device, specifically the commands it can support. For example, commands can be represented by a command identifier (ID) and a specific value associated with that ID. For instance, command ID = 1 indicates that the command is a power-on or power-off command; command ID = 1 with a value of 0 indicates a power-off command, while command ID = 1 with a value of 1 indicates a power-on command. Command ID = 2 indicates that the command is a hibernation command; command ID = 2 with a value of 0 indicates a hibernation command, while command ID = 2 with a value of 1 indicates a hibernation-wake-up command.
[0324] Optionally, S144, the secondary processor of the controlled device verifies the instruction based on the authentication information in the device configuration message.
[0325] After parsing the instruction, the controlled device can verify the instruction, that is, verify whether the instruction was sent by an authorized master control device. S144 is an optional operation.
[0326] S145, the secondary processor of the controlled device sends power-on, sleep wake-up, sleep wake-up or restart commands to the EC via bus connection.
[0327] Specifically, the secondary processor of the controlled device establishes a bus connection with the EC in advance, and sends the parsed power-on, hibernation wake-up, sleep wake-up or restart commands to the EC based on the bus connection, so that the EC controls the main processor to execute the corresponding tasks.
[0328] S146, the EC of the controlled device notifies the main processor to power on, wake from hibernation, wake from sleep, or restart.
[0329] S147, the main processor of the controlled device starts up, and the controlled device switches to the power-on state.
[0330] Specifically, the main processor of the controlled device starts up and begins working under the control of the EC, causing the controlled device to switch to the power-on state.
[0331] S148, the main processor of the controlled device notifies the secondary processor to disable the reconnection function.
[0332] Specifically, after the main processor of the controlled device starts working, it can establish a connection with the server. However, in order to prevent the secondary processor from taking the first place to establish a connection with the server, the main processor needs to control the secondary processor to disable the reconnection function.
[0333] S149, the secondary processor of the controlled device disables the reconnection function.
[0334] S150, the main processor of the controlled device requests the establishment of a second connection to the server based on the server login information.
[0335] Specifically, the main processor of the controlled device pre-stores the server login information (login account and password) mentioned above. The server login account and password can be the same as the login account and password used by the secondary processor mentioned above.
[0336] S151, the server notifies the controlled device that the first connection to the secondary processor has been disconnected.
[0337] Specifically, since only one client can log in to the same account, after the server receives the request to establish a connection from the main processor of the controlled device, the server will automatically exit the secondary processor of the controlled device that was previously logged in with the same login account, and notify the secondary processor of the controlled device that the first connection has been broken.
[0338] S152, the server notifies the controlled device's main processor that a second connection has been established.
[0339] Specifically, while the server disconnects from the secondary processor of the controlled device, it establishes a second connection with the primary processor of the controlled device and notifies the primary processor of the controlled device that the second connection has been established.
[0340] As can be seen, S151 and S152 occur simultaneously, thus the server and the controlled device establish a seamless connection. This allows users of the main control device to be unaware of the controlled device going offline, providing them with a seamless remote control experience.
[0341] S153, the main processor of the controlled device notifies the secondary processor to release resources.
[0342] Specifically, after the main processor of the controlled device successfully establishes a second connection with the server, the controlled device does not need to use a secondary processor to replace the main processor to realize the remote control function. Therefore, the main processor of the controlled device will notify the secondary processor to release resources, thereby reducing the workload of the secondary processor and allowing the secondary processor to enter a low-power working mode.
[0343] S154, the secondary processor of the controlled device exits the network and clears the temporary data in RAM.
[0344] Specifically, the secondary processor releases resources including, but not limited to: exiting the network and clearing temporary data in RAM. The network to be exited is the network accessed based on the network configuration information in the configuration message, as described in S122 above. The temporary data in RAM includes, but is not limited to, data parsed from the bus heartbeat message into memory, such as instruction information parsed from the profile file.
[0345] Phase 3-2 (S161-S169): After the controlled device is powered on locally, wakes up from hibernation or sleep, it disconnects the first connection and establishes a second connection with the server through the main processor to realize the remote control function.
[0346] S161, the main processor of the controlled device receives input for power-on, sleep wake-up or sleep wake-up.
[0347] Specifically, when the controlled device is powered off, the main processor of the controlled device can receive a power-on input; when the controlled device is in hibernation mode, the main processor of the controlled device can receive a hibernation wake-up input; when the controlled device is in sleep mode, the main processor of the controlled device can receive a sleep wake-up input; and when the controlled device is in power-on, hibernation, or sleep mode, the main processor of the controlled device can also receive a restart input.
[0348] The aforementioned input may be triggered by an operation on a physical button of the controlled device or by an operation on a virtual control displayed on the controlled device. This application embodiment does not limit this.
[0349] The aforementioned input can be directly detected by the main processor of the controlled device, or detected by the EC of the controlled device and transmitted to the main processor. This application embodiment does not limit this.
[0350] S162-S169 correspond one-to-one with S147-S154 in stage 3-1. For details, please refer to the previous description, which will not be repeated here.
[0351] Next, in conjunction with the above... Figure 3B The software architecture of the controlled device is introduced, and Figure 10 The device interaction process is shown below. Next, we will introduce the detailed module interaction process of each stage.
[0352] refer to Figure 11 , Figure 11 This example illustrates the detailed module interaction process included in the information synchronization phase.
[0353] like Figure 11 As shown, the synchronization phase is jointly executed by the main processor and the secondary processor of the controlled device, specifically involving the following modules: a system manager and a bus communication management module running on the main processor, and a configuration management module, a wake-up management module, and a remote connection management module running on the secondary processor. The configuration management module includes a bus communication management module, a bus heartbeat management module, a connection configuration management module, and a device configuration management module. The wake-up management module includes a wake-up service management module, and the remote connection management module includes a network management module. For a more detailed description of each module, please refer to the aforementioned... Figure 3BDescription of the software architecture of the controlled device shown.
[0354] like Figure 11 As shown, the information synchronization stage includes the following interactive process:
[0355] S711, the controlled device powers on and starts the system manager.
[0356] S712, the system manager of the controlled device starts the bus communication management module in the main processor.
[0357] S713-S719 describes the interaction process by which the main processor and the slave processor maintain bus connection through synchronous bus heartbeat messages.
[0358] S713, the bus communication management module in the main processor of the controlled device establishes a bus connection with the bus communication management module in the secondary processor.
[0359] S714, the bus communication management module in the main processor of the controlled device sends a bus heartbeat message to the bus communication management module in the secondary processor.
[0360] Specifically, bus heartbeat messages can be used to maintain the bus connection between the master processor and the slave processor, enabling the master processor to send control commands to the slave processor through the bus connection.
[0361] S715, the bus communication management module in the controlled device's secondary processor sends a bus heartbeat message to the bus heartbeat management module.
[0362] S716, the bus heartbeat management module in the controlled device's secondary processor detects the bus heartbeat status.
[0363] Specifically, the bus heartbeat management module in the controlled device's secondary processor detects the bus heartbeat status based on the received bus heartbeat messages.
[0364] If the bus heartbeat message is parsed from the bus heartbeat message of the bus heartbeat management module and it is found that the bus heartbeat message was received for the first time during a power-on process, then the bus heartbeat status is considered to be heartbeat established at this time.
[0365] If the bus heartbeat message parsed from the bus heartbeat management module indicates that no bus heartbeat message was received during a power-on process and after the heartbeat was established, then the bus heartbeat status at this time is considered to be heartbeat loss.
[0366] If the bus heartbeat message is parsed from the bus heartbeat message of the bus heartbeat management module and it is found that a bus heartbeat message was received during a power-on process and after the heartbeat was lost, then the bus heartbeat status at this time is considered to be heartbeat recovery.
[0367] S717, the bus heartbeat management module in the controlled device's secondary processor sends the bus heartbeat status to the wake-up service management module.
[0368] Specifically, the bus heartbeat management module transmits the heartbeat status to the wake-up management module, which then determines whether to activate the remote connection management module based on the heartbeat status, in order to establish / disconnect a long connection with the server.
[0369] S718-S719, the bus heartbeat management module in the secondary processor of the controlled device replies to the bus communication management module in the main processor through the bus communication management module.
[0370] Specifically, the bus heartbeat management module in the secondary processor of the controlled device replies to the bus communication management module in the primary processor through the bus communication management module. This can be used by the primary processor to know the online status of the secondary processor, thereby maintaining the bidirectional communication bus connection.
[0371] The above-mentioned synchronous bus heartbeat process involves the master processor periodically sending heartbeat messages to the slave processor after the controlled device is powered on, and the slave processor responding with corresponding bus heartbeat messages.
[0372] S721-S729 describes the interactive process of synchronizing device configuration information to the sub-processor when the main processor's query comparison results are different.
[0373] S721, the bus communication management module in the main processor of the controlled device queries the device configuration information from the bus communication management module in the secondary processor.
[0374] Specifically, device configuration information can also be called device configuration messages. For more information on device configuration information, please refer to the previous description, which will not be repeated here.
[0375] In S722-S725, the bus communication management module in the secondary processor of the controlled device reads the device configuration information through the device configuration management module and returns it to the bus communication management module in the main processor.
[0376] Specifically, since the secondary processor of the controlled device stores the device configuration information synchronized by the primary processor in the device configuration management module, before the primary processor of the controlled device synchronizes the device configuration information to the secondary processor, it needs to query the device configuration management module of the secondary processor to see if there is already information with the same device configuration information to be synchronized. If there is the same information, it will not be synchronized again; otherwise, it will continue to synchronize.
[0377] In addition, since the secondary processor of the controlled device may restore factory settings and clear the previously stored synchronized device configuration information, and the primary processor does not know when the secondary processor will restore factory settings, the primary processor needs to query and compare with the secondary processor before synchronizing the information every time the controlled device is powered on.
[0378] S726, the bus communication management module of the main processor of the controlled device compares the device configuration information.
[0379] Specifically, the bus communication management module of the main processor of the controlled device compares the device configuration information to be synchronized with the device configuration information queried from the sub-processor. If the comparison results are the same, the device configuration information will not be synchronized again. If the comparison results are different, the subsequent S727-S729 will be executed.
[0380] S727: When the comparison results are different, the bus communication management module of the main processor of the controlled device sends the device configuration information to the bus communication management module of the secondary processor.
[0381] S728, the bus communication module of the secondary processor of the controlled device sends device configuration information to the device configuration management module.
[0382] S729, the device configuration management module of the secondary processor of the controlled device stores device configuration information.
[0383] Specifically, after receiving the device configuration information sent by the bus communication management module, the device configuration management module of the controlled device's secondary processor stores it in NVM to ensure that the device configuration information is not lost after power failure. However, the device configuration information will be cleared when the secondary processor is restored to factory settings.
[0384] S731-S742 describes the interactive process of synchronizing connection configuration information to the subprocessor when the main processor's query comparison results are different.
[0385] S731, the bus communication management module in the main processor of the controlled device queries the connection configuration information from the bus communication management module in the secondary processor.
[0386] Specifically, connection configuration information can also be called connection configuration messages. For more information on connection configuration information, please refer to the previous description, which will not be repeated here.
[0387] S732-S737: The bus communication management module in the secondary processor of the controlled device reads the connection configuration information through the connection configuration management module and the network association module and returns it to the bus communication management module in the main processor.
[0388] Specifically, since the secondary processor of the controlled device stores the connection configuration information synchronized by the primary processor in the network management module, before the primary processor of the controlled device synchronizes the connection configuration information to the secondary processor, it needs to query the network management module of the secondary processor to see if there is already information with the same connection configuration information to be synchronized. If there is the same information, it will not be synchronized again; otherwise, it will continue to synchronize.
[0389] In addition, since the secondary processor of the controlled device may be reset to factory settings and thus clear the previously stored synchronized connection configuration information, and the primary processor does not know when the secondary processor is reset to factory settings, the primary processor needs to query and compare with the secondary processor before synchronizing the information each time the controlled device is powered on.
[0390] S738, the bus communication management module of the main processor of the controlled device compares the connection configuration information.
[0391] Specifically, the bus communication management module of the main processor of the controlled device compares the connection configuration information to be synchronized with the connection configuration information queried from the sub-processor. If the comparison results are the same, the connection configuration information will not be synchronized again. If the comparison results are different, the subsequent S739-S742 will be executed.
[0392] S739, when the comparison results are different, the bus communication management module of the main processor of the controlled device sends connection configuration information to the bus communication management module of the secondary processor.
[0393] S740-S741, the bus communication module of the secondary processor of the controlled device sends connection configuration information to the network association module through the connection configuration management module.
[0394] S742, the network management module of the secondary processor of the controlled device stores connection configuration information.
[0395] Specifically, after receiving the connection configuration information, the network management module of the secondary processor of the controlled device stores it in NVM to ensure that the connection configuration information is not lost after power failure. However, the connection configuration information will be cleared when the secondary processor is restored to factory settings.
[0396] This application embodiment does not restrict the execution order of the above three types of synchronization information. For example, the synchronization of device configuration information can be executed during or after the synchronization of connection configuration information. This application embodiment does not restrict this.
[0397] It is evident that by adopting the aforementioned Figure 11 The interactive method for synchronizing information between the master and slave processors, as shown, reduces write overhead on the slave processor and extends its lifespan. Specifically, due to the lower specifications of the slave processor, the number of writes to the NVM (e.g., flash memory) integrated in the slave processor is limited. Therefore, before each information synchronization, the controlled device first needs to query the master processor to see if the information in the slave processor is consistent with the information to be synchronized. Only if there is a discrepancy will the information be written to the slave processor.
[0398] The information to be synchronized from the main processor to the server, as described in S731-S742 above, can also be referred to as the first information.
[0399] refer to Figure 12 , Figure 12 This example illustrates the detailed module interaction process involved in establishing a connection with the server after the controlled device shuts down abnormally or normally.
[0400] like Figure 12 As shown, the abnormal shutdown / normal shutdown phase is jointly executed by the main control device (not shown), the server, and the main and secondary processors of the controlled device. Specifically, it involves the following modules: the system manager and bus communication management module running on the main processor, and the configuration management module, wake-up management module, and remote connection management module running on the secondary processor. The configuration management module includes the bus communication management module, bus heartbeat management module, connection configuration management module, and device configuration management module. The wake-up management module includes the wake-up service management module and EC control module, and the remote connection management module includes the login module and network management module. For a more detailed description of each module, please refer to the aforementioned... Figure 3B A detailed description of the software architecture of the controlled device shown is omitted here.
[0401] like Figure 12 As shown, the abnormal shutdown / normal shutdown stage includes the following interactive flow:
[0402] Sections S811-S821 describe the interaction process for establishing a connection with the server after the controlled device abnormally shuts down. Sections S811-S821 can also be used to describe the interaction process for establishing a connection with the server after the controlled device abnormally goes into hibernation, sleep, or is powered on but malfunctions. Here, we will only introduce the abnormal shutdown process as an example.
[0403] S811: After the controlled device receives a shutdown input, it shuts down the system manager in the main processor.
[0404] S812, the main processor of the controlled device is shut down.
[0405] Specifically, after the system manager in the main processor of the controlled device receives the shutdown input, it begins to control the controlled device to execute the shutdown procedure, so that most modules except for the subprocessor and EC are shut down, that is, power is cut off and they stop working.
[0406] S813, the bus heartbeat management module in the secondary processor of the controlled device detected that the bus heartbeat was lost.
[0407] Specifically, in one possible scenario, when the controlled device receives a shutdown input, the main processor may suddenly stop working without notifying the secondary processor in time. The bus connection established between the main processor and the secondary processor when the controlled device is powered on will also be disconnected accordingly, causing the main processor to be unable to send bus heartbeat messages to the secondary processor periodically. Therefore, the secondary processor can detect the timeout of receiving the bus heartbeat message through the bus heartbeat management module, and thus determine that the bus heartbeat is lost.
[0408] S814, the bus heartbeat management module in the secondary processor of the controlled device notifies the wake-up service management module that the bus heartbeat has been lost.
[0409] S815, the wake-up service management module in the secondary processor of the controlled device obtains the network configuration information from the device configuration management module.
[0410] Specifically, the device configuration management module pre-stores device configuration information synchronized by the main processor. This device configuration information includes, but is not limited to, device identifier, network configuration information, profile file, etc.
[0411] The device identifier is used by the controlled device to register and log in to the server, allowing the server to store the association between the login account and the controlled device identifier. Network configuration information includes a network identifier and password, such as a Wi-Fi name and password, which the controlled device uses to access the network. The profile file includes information about the instructions supported by the controlled device, which the co-processor uses to parse remote control instructions.
[0412] S816, the wake-up service management module in the secondary processor of the controlled device accesses the network based on network configuration information.
[0413] Specifically, after the wake-up service management module obtains the network configuration information, it can access the network based on this information. This allows it to establish connections with other devices, such as servers, for data communication.
[0414] S817, the wake-up service management module in the secondary processor of the controlled device obtains the profile file in the device configuration information from the device configuration management module.
[0415] Specifically, the device configuration management module pre-stores device configuration information synchronized by the main processor. This device configuration information includes, but is not limited to, device identifiers, network configuration information, profile files, etc. Detailed descriptions of this information can be found in the preceding text and will not be repeated here.
[0416] It is understood that S817 can be executed synchronously with S815, and this application embodiment does not limit this.
[0417] S818, the wake-up service management module in the secondary processor of the controlled device starts the login module and carries the profile file.
[0418] S819, the login module in the secondary processor of the controlled device obtains the server login information from the connection configuration information in the network management module.
[0419] Specifically, the network management module pre-stores connection configuration information synchronized with the main processor. This connection configuration information includes, but is not limited to, server login information, such as login account and password.
[0420] In S820, the login module in the secondary processor of the controlled device establishes a first connection with the server based on the server login information.
[0421] Specifically, the login module of the secondary processor can send a login request to the server, carrying the server login information. Since the primary processor has been pre-registered with the server, the server has pre-stored the login information of the controlled device, and can then verify the server login information sent by the secondary processor. If the verification is successful, the secondary processor is allowed to log in to the server, which is equivalent to the secondary processor successfully establishing the first connection with the server through the login module.
[0422] S821, the login module in the secondary processor of the controlled device enables the reconnection function.
[0423] Specifically, after the secondary processor establishes a connection with the server through the login module, the login module of the secondary processor automatically enables the reconnection function so that the connection can be restored after an abnormal disconnection.
[0424] Sections S831-S841 describe the interaction process for establishing a connection with the server after the controlled device is normally shut down. Sections S831-S841 can also be used to describe the interaction process for establishing a connection with the server after the controlled device is in normal hibernation, sleep, or power-on but malfunctions. Here, we will only introduce the abnormal shutdown as an example.
[0425] S831, the system manager in the main processor of the controlled device receives the shutdown input.
[0426] Specifically, after the controlled device receives a shutdown input, it will transmit it to the system manager, causing the system manager to shut down.
[0427] In S832, the system manager in the main processor of the controlled device sends a command to the bus communication module to notify the secondary processor to log in to the server.
[0428] Specifically, in one possible scenario, when the controlled device receives a shutdown input, the main processor will not suddenly stop working. Instead, it will first notify the secondary processor to log in to the server before starting to control the controlled device to execute the shutdown procedure, so that most modules except for the secondary processor and EC will be shut down, i.e., power outage and stop working.
[0429] S833-S834, the bus communication module in the secondary processor of the controlled device notifies the wake-up service management module to log in to the server through the bus communication module of the secondary processor.
[0430] Specifically, in one possible scenario, when the controlled device receives a shutdown input, the main processor may suddenly stop working without notifying the secondary processor in time. The bus connection established between the main processor and the secondary processor when the controlled device is powered on will also be disconnected accordingly, causing the main processor to be unable to send bus heartbeat messages to the secondary processor periodically. Therefore, the secondary processor can detect the timeout of receiving the bus heartbeat message through the bus heartbeat management module, and thus determine that the bus heartbeat is lost.
[0431] S835-S841 correspond one-to-one with S815-S821 in the abnormal shutdown phase. Please refer to the previous description for details, which will not be repeated here.
[0432] It is evident that by adopting the aforementioned Figure 12 Following the interactive method shown, regardless of whether the controlled device shuts down normally or abnormally, causing the main processor of the controlled device to suddenly lose power and stop working, the secondary processor of the controlled device can learn of this situation and then establish a connection with the server through the secondary processor to realize the remote control function.
[0433] refer to Figure 13 , Figure 13 This example illustrates the detailed module interaction process involved in establishing a connection with the server after the controlled device is remotely powered on / locally powered off.
[0434] like Figure 13 As shown, the remote power-on / local power-on stage is jointly executed by the main control device (not shown), the server, the main processor and secondary processor of the controlled device, and the EC. Specifically, it involves the following modules: the system manager and bus communication management module running on the main processor; and the configuration management module, wake-up management module, and remote connection management module running on the secondary processor. The configuration management module includes the bus communication management module and the connection configuration management module. The wake-up management module includes the wake-up service management module and the EC control module, and the remote connection management module includes the login module and the device control module. For a more detailed description of each module, please refer to the aforementioned... Figure 3B A detailed description of the software architecture of the controlled device shown is omitted here.
[0435] like Figure 13 As shown, the remote power-on / local power-off stage includes the following interactive process:
[0436] S911-S930 describes the interaction process of establishing a connection with the server after the controlled device is remotely powered on. The interaction process of establishing a connection with the server after the controlled device remotely wakes from hibernation, sleep, or restarts can also be found in S911-S930; here, we will only introduce the remote power-on example.
[0437] S911, the server receives a power-on command for the controlled device sent by the master control device.
[0438] Specifically, the master control device can add one or more controlled devices, and users can remotely control the added remote controlled devices from the master control device. See the preceding section for details. Figures 6A-6E After remotely powering on Xiao Li's MagicBook 14 on the main control device, the main control device can send a power-on command for Xiao Li's MagicBook 14 to the server.
[0439] The boot command can be represented by a command ID and a corresponding specific value.
[0440] S912, the server sends a power-on command to the device control module in the secondary processor of the controlled device.
[0441] S913, the device control module in the secondary processor of the controlled device obtains the profile file from the login module.
[0442] S914, the device control module in the secondary processor of the controlled device parses the boot instruction based on the profile file.
[0443] S915, the device control module in the secondary processor of the controlled device parses the boot command based on the profile file.
[0444] Specifically, after receiving the remote control command sent by the server, the device control module in the secondary processor of the controlled device does not know the specific event corresponding to the command. Therefore, it needs to parse the event corresponding to the power-on command based on the command set described in the profile file.
[0445] S916-S917, the device control module in the secondary processor of the controlled device notifies the EC to wake up the controlled device by waking up the service management module and the EC control module.
[0446] S918, the EC notification of the controlled device to the main processor wakes up the controlled device.
[0447] Specifically, after the EC notifies the main processor to wake up the controlled device, the main processor can start the system manager, bus communication module, and other modules, etc.
[0448] S919, the main processor of the controlled device starts.
[0449] Specifically, once the main processor of the controlled device has started up, the controlled device switches to the power-on state.
[0450] In S920, the main processor of the controlled device establishes a bus connection with the bus communication module in the secondary processor.
[0451] Specifically, the bus communication module in the main processor can establish a bus connection with the bus communication module in the secondary processor.
[0452] S921-S923: The main processor of the controlled device notifies the login module to disable the reconnection function through the bus communication module and connection configuration management module in the secondary processor.
[0453] S924, the login module in the secondary processor of the controlled device disables the reconnection function.
[0454] S925, the main processor of the controlled device establishes a second connection with the server based on the server login information.
[0455] Specifically, the main processor of the controlled device has pre-installed network configuration information, server login information, etc. Therefore, after the main processor connects to the network, it can request to establish a second connection with the server based on the server login information.
[0456] S926, the server notifies the controlled device that the first connection of the login module in the secondary processor has been disconnected.
[0457] The controlled device disconnects from the server's first connection via the second connection established by the main processor and the server, which is also disconnected from the server by the secondary processor. This is because the first connection is an MQTT connection. The main processor and the secondary processor use the same login account to establish a connection with the server. The server only retains a connection with one device, namely the main processor that most recently requested the connection.
[0458] S927-S929: The main processor of the controlled device notifies the login module to release resources through the bus communication management module and connection configuration management module in the secondary processor.
[0459] Optionally, the main processor of the controlled device may also notify the service wake-up management module to release resources through the bus communication management module and connection configuration management module in the secondary processor, so that the service wake-up management module can clear the temporary data in RAM, such as disconnecting from the connected network.
[0460] S930, the login module in the secondary processor of the controlled device clears the temporary data in RAM.
[0461] Specifically, the recording module clears temporary data in RAM, including instruction sets and other information parsed from the profile file.
[0462] Sections S941-S954 describe the interaction process of the controlled device establishing a connection with the server after local power-on. Sections S941-S954 also describe the interaction process of the controlled device establishing a connection with the server after local sleep / wake-up, sleep / wake-up, or restart. Here, we will only introduce the local power-on process as an example.
[0463] S941, the EC of the controlled device receives the power-on input.
[0464] Specifically, this power-on input can be triggered by an operation on a physical button, such as the aforementioned operation on... Figure 7A Operation of the power button 511.
[0465] S942, the main processor of the controlled device starts.
[0466] Specifically, after the main processing unit of the controlled device completes its startup process, the controlled device switches to the power-on state.
[0467] S943-S954 correspond one-to-one with S919-S930 in the remote power-on stage. Please refer to the previous description for details, which will not be repeated here.
[0468] It is evident that by adopting the aforementioned Figure 13 The interaction method shown ensures that the controlled device reliably receives remote control commands. Specifically: When the controlled device is powered on, the main processor first instructs the secondary processor to disable the reconnection function. Then, the main processor establishes a communication connection with the server, automatically disconnecting the secondary processor's connection to the server. This not only ensures a seamless transition between the main processor's communication connection and the server's long-lived connection with the secondary processor, guaranteeing a constant connection between the controlled device and the server, thus eliminating any anomalies perceived by the user on the main control device, but also prevents the secondary processor from triggering its reconnection function after being directly disconnected by the main processor, thus avoiding contention for the server connection.
[0469] refer to Figure 14 , Figure 14 This example illustrates the detailed module interaction process involved in establishing a connection with the server when the secondary processor of the controlled device is powered off and then powered on again.
[0470] like Figure 14As shown, the abnormal shutdown / normal shutdown phase is jointly executed by the main control device (not shown), the server, and the main and secondary processors of the controlled device. Specifically, it involves the following modules: the system manager and bus communication management module running on the main processor, and the configuration management module, wake-up management module, and remote connection management module running on the secondary processor. The configuration management module includes the bus communication management module, bus heartbeat management module, connection configuration management module, and device configuration management module. The wake-up management module includes the wake-up service management module and EC control module, and the remote connection management module includes the login module and network management module. For a more detailed description of each module, please refer to the aforementioned... Figure 3B A detailed description of the software architecture of the controlled device shown is omitted here.
[0471] Figure 14 The interaction process shown occurs after the main processor and the secondary processor of the controlled device complete information synchronization, and after the controlled device is powered off, i.e., after the aforementioned... Figures 11-12 Following the introduction of the interaction process, that is, during execution Figure 14 Prior to the interaction process shown, the controlled device has already established a first connection with the server through the secondary processor.
[0472] S511, the bus heartbeat management module in the secondary processor of the controlled device starts the total heartbeat timer. If no bus heartbeat message is received during the timer, the subsequent S512-S519 are executed.
[0473] Specifically, after the secondary processor loses power and then regains power, the secondary processor's bus heartbeat management module detects the bus heartbeat message. If no bus heartbeat message is received, the secondary processor's startup module is automatically triggered to start and restore the first connection during the service period, as detailed in S512-S519.
[0474] S512-S519 correspond one-to-one with the aforementioned S814-S821, which will not be detailed here.
[0475] In S520, after the bus heartbeat management module in the secondary processor of the controlled device detects the bus heartbeat recovery, it indicates that the controlled device has been powered on and the main processor can start working. Therefore, it switches to establishing a second connection with the server through the main processor. The process of switching to establishing a second connection with the server through the main processor can be referred to the descriptions of S920-S930 above, which will not be elaborated here.
[0476] It can be seen that the adoption Figure 14Following the method shown, when the controlled device is powered off, the secondary processor will establish a connection with the server. However, if the secondary processor loses power (e.g., runs out of power), the remote control function implemented by the controlled device through the secondary processor will be temporarily lost. If the secondary processor is subsequently powered on again, the controlled device may still be in a powered-off state. The controlled device will not establish a connection with the server through the primary processor, nor will it establish a bus connection with the secondary processor to synchronize information. At this time, the secondary processor can sense this state on its own through the bus heartbeat, automatically triggering the reading of previously synchronized information from the NVM (e.g., flash), and then restore the first connection with the server, thereby restoring the remote control capability.
[0477] It should be understood that the steps in the above-described method embodiments provided in this application can be implemented by integrated logic circuits in the processor hardware or by instructions in software form. The method steps disclosed in the embodiments of this application can be directly implemented by a hardware processor, or implemented by a combination of hardware and software modules in the processor.
[0478] This application also provides an electronic device that may include a memory and a processor. The memory may be used to store a computer program; the processor may be used to invoke the computer program in the memory to cause the electronic device to perform the method in any of the above embodiments.
[0479] This application also provides a chip system including at least one processor for implementing the functions involved in the methods performed by the electronic device in any of the above embodiments.
[0480] In one possible design, the chip system also includes a memory for storing program instructions and data, which may be located within or outside the processor.
[0481] The chip system can consist of chips or include chips and other discrete components.
[0482] Optionally, the chip system may contain one or more processors. These processors can be implemented in hardware or software. When implemented in hardware, the processor can be a logic circuit, an integrated circuit, etc. When implemented in software, the processor can be a general-purpose processor, implemented by reading software code stored in memory.
[0483] Optionally, the chip system may contain one or more memories. The memory may be integrated with the processor or disposed separately from it; this application embodiment does not limit this. For example, the memory may be a non-transient processor, such as a read-only memory (ROM), which may be integrated with the processor on the same chip or disposed separately on different chips. This application embodiment does not specifically limit the type of memory or the arrangement of the memory and processor.
[0484] For example, the chip system may be a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), a system on chip (SoC), a central processor unit (CPU), a network processor (NP), a digital signal processor (DSP), a micro controller unit (MCU), a programmable logic device (PLD), or other integrated chips.
[0485] This application also provides a computer program product comprising: a computer program (also referred to as code or instructions) that, when run, causes a computer to perform the method executed by the electronic device in any of the above embodiments.
[0486] This application also provides a computer-readable storage medium storing a computer program (also referred to as code or instructions). When the computer program is run, it causes the computer to perform the method executed by the electronic device in any of the above embodiments.
[0487] The various embodiments of this application can be combined arbitrarily to achieve different technical effects.
[0488] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented, in whole or in part, as 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, all or part of the processes or functions described in this application are generated. 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 computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium accessible to a computer or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid-state drive).
[0489] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. This program can be stored in a computer-readable storage medium, and when executed, it can include the processes described in the above method embodiments. The aforementioned storage medium includes various media capable of storing program code, such as ROM or random access memory (RAM), magnetic disks, or optical disks.
[0490] In summary, the above description is merely an embodiment of the technical solution of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc., made according to the disclosure of the present invention should be included within the scope of protection of the present invention.
Claims
1. An electronic device, characterized in that, The electronic device includes: a main processor and a secondary processor. The main processor integrates a high-speed cache memory, and the secondary processor integrates a non-volatile memory (NVM). The performance of the main processor is superior to that of the secondary processor. After the electronic device is powered on, with both the main processor and the sub-processor in working condition, the main processor sends a bus heartbeat message to the sub-processor via a bus connection. When the main processor finds that the information in the sub-processor is inconsistent with the information to be synchronized in the main processor, the main processor sends the information to be synchronized to the sub-processor. The information to be synchronized includes connection configuration information and device configuration information. The sub-processor writes the connection configuration information and the device configuration information into the NVM. The connection configuration information includes server login information, which is used by the sub-processor and the main processor to establish a long connection with the server using the same server login information. The device configuration information includes a Profile file, which describes the instructions supported by the electronic device and is used by the sub-processor to parse and respond to remote control instructions. The Profile file describes the meaning of the instruction identifier and its corresponding value, wherein the first instruction identifier corresponds to a first value representing a power-off instruction, the first instruction identifier corresponds to a second value representing a power-on instruction, the second instruction identifier corresponds to the first value representing a hibernation instruction, and the second instruction identifier corresponds to the second value representing a hibernation wake-up instruction. In the event of an abnormal shutdown of the main processor, the bus connection between the main processor and the secondary processor is disconnected; if the secondary processor does not receive a bus heartbeat message from the main processor within a timeout period, it determines that the main processor is in a non-working state. After receiving a power-off command, the main processor sends a second command to the sub-processor to log in to the server. The main processor shuts down normally. Upon receiving the second command from the main processor, the sub-processor determines that the main processor is in a non-working state. The non-working states of the main processor include the following: the main processor is powered off, and the main processor is powered on and faulty. When the main processor is not in operation, the secondary processor establishes a first connection with the server based on the connection configuration information and enables the reconnection function. When the secondary processor loses power, it disconnects from the first connection with the server. When the secondary processor is powered on again, it re-establishes the first connection with the server based on the reconnection function. When the server receives a power-on command for the electronic device, it sends a power-on command to the secondary processor based on the first connection. The power-on command carries an identifier of a first command and a corresponding value. The secondary processor receives the identifier of the first command and the corresponding value sent by the server based on the first connection, parses the meaning of the identifier of the first command and the corresponding value based on the Profile file, and in response to the first command, notifies the main processor to switch to the working state. The main processor being in the working state includes the main processor being powered on and not faulty. The first command includes a power-on, sleep wake-up, sleep wake-up, or restart command. The main processor is used to disable the reconnection function of the secondary processor after switching to the working state, and establish a second connection with the server. Once the second connection is established, the first connection is disconnected.
2. The electronic device according to claim 1, characterized in that, The electronic device also includes an embedded control processor EC; The secondary processor is specifically used to notify the primary processor to switch to the working state via the EC.
3. The electronic device according to claim 1 or 2, characterized in that, The main processor is also used to send a network identifier and a first password to the sub-processor when it is in operation; The secondary processor is also used to access the network based on the network identifier and the first password when the main processor is not in operation.
4. The electronic device according to claim 1, characterized in that, The secondary processing is also used to perform the following operations: When the secondary processor is powered off, the first connection is disconnected; If the secondary processor does not receive a bus heartbeat message from the primary processor after being powered off and then powered on again, the secondary processor shall re-establish the first connection with the server.
5. The electronic device according to claim 1, characterized in that, The main processor is also configured to notify the subprocessor to clear the data in the random access memory (RAM) after establishing the second connection with the server.
6. The electronic device according to claim 1, characterized in that, The main process is also configured to perform the following operations after establishing the second connection with the server: The main processor receives a third instruction sent by the server based on the second connection. The third instruction includes instructions to shut down, sleep, hibernate, restart, or play music. In response to the third instruction, the main processor executes the corresponding task.
7. The electronic device according to claim 1, characterized in that, The secondary processor includes a configuration management module, which is used to determine the working status of the primary processor based on the bus heartbeat message of the primary processor.
8. The electronic device according to claim 1, characterized in that, The secondary processor includes a remote connection management module, which is used to establish a first connection with the server and receive the first instruction based on the first connection.
9. The electronic device according to claim 1, characterized in that, The secondary processor includes a wake-up management module, which is used to notify the primary processor to switch to the working state.
10. A remote control method, characterized in that, The method is applied to an electronic device, which includes a main processor and a secondary processor. The main processor integrates a high-speed cache memory, and the secondary processor integrates non-volatile memory (NVM). The performance of the main processor is superior to that of the secondary processor. The method includes: After the electronic device is powered on, with both the main processor and the sub-processor in working condition, the main processor sends a bus heartbeat message to the sub-processor via a bus connection. When the main processor finds that the information in the sub-processor is inconsistent with the information to be synchronized in the main processor, the main processor sends the information to be synchronized to the sub-processor. The information to be synchronized includes connection configuration information and device configuration information. The sub-processor writes the connection configuration information and the device configuration information into the NVM. The connection configuration information includes server login information, which is used by the sub-processor and the main processor to establish a long connection with the server using the same server login information. The device configuration information includes a Profile file, which describes the instructions supported by the electronic device and is used by the sub-processor to parse and respond to remote control instructions. The Profile file describes the meaning of the instruction identifier and its corresponding value, wherein the first instruction identifier corresponds to a first value representing a power-off instruction, the first instruction identifier corresponds to a second value representing a power-on instruction, the second instruction identifier corresponds to the first value representing a hibernation instruction, and the second instruction identifier corresponds to the second value representing a hibernation wake-up instruction. In the event of an abnormal shutdown of the main processor, the bus connection between the main processor and the secondary processor is disconnected; if the secondary processor of the electronic device does not receive a bus heartbeat message from the main processor within a timeout period, it determines that the main processor is in a non-working state. After receiving a shutdown command, the main processor of the electronic device sends a second command to the sub-processor to log in to the server. The main processor shuts down normally. Upon receiving the second command sent by the main processor, the sub-processor of the electronic device determines that the main processor is in a non-working state. The non-working states of the main processor include the following: the main processor is powered off, and the main processor is powered on and faulty. If the main processor is determined to be in a non-working state, the secondary processor establishes a first connection with the server based on the connection configuration information and enables the reconnection function. When the secondary processor loses power, it disconnects from the first connection with the server. When the secondary processor is powered on again, it re-establishes the first connection with the server based on the reconnection function. When the server receives a power-on command for the electronic device, it sends a power-on command to the secondary processor via the first connection. The power-on command carries an identifier of a first command and a corresponding value. The secondary processor receives the identifier of the first command and the corresponding value sent by the server via the first connection, parses the meaning of the identifier of the first command and the corresponding value based on the Profile file, and responds to the first command by notifying the main processor to switch to the working state. The main processor being in the working state includes a state where the main processor is powered on and not faulty. The first command includes commands for powering on, waking from hibernation, waking from sleep, or restarting. After the main processor of the electronic device switches to the working state, it disables the reconnection function of the secondary processor and establishes a second connection with the server. Once the second connection is established, the first connection is disconnected.
11. The method according to claim 10, characterized in that, The electronic device also includes an embedded control processor EC; Specifically, the electronic device notifies the main processor to switch to the working state through the secondary processor: the electronic device notifies the main processor to switch to the working state through the secondary processor and the EC.
12. The method according to claim 10 or 11, characterized in that, The method further includes: When the main processor of the electronic device is in the operating state, the electronic device sends a network identifier and a first password to the sub-processor through the main processor; When the main processor of the electronic device is not in operation, the secondary processor of the electronic device accesses the network based on the network identifier and the first password.
13. The method according to claim 10, characterized in that, Before the electronic device establishes a first connection with the server via the subprocessor, the method further includes: When the secondary processor is powered off, the first connection is disconnected; If the electronic device does not receive the bus heartbeat message from the main processor after the secondary processor is powered off and then powered on again, it shall re-establish the first connection with the server through the secondary processor.
14. The method according to claim 10, characterized in that, After the electronic device establishes a second connection with the server through the main processor, the method further includes: The main processor notifies the subprocessor to clear the data in the random access memory (RAM).
15. The method according to claim 10, characterized in that, After the electronic device establishes a second connection with the server through the main processor, the method further includes: The electronic device receives a third instruction sent by the server through the main processor based on the second connection. The third instruction includes instructions to power off, sleep, hibernate, restart, or play music. In response to the third instruction, the corresponding task is executed by the main processor.
16. A chip system, characterized in that, The chip system includes at least one processor and a memory, the memory storing program instructions, and the processor executing the program instructions to implement the method as described in any one of claims 10-15.
17. A computer-readable storage medium comprising instructions, characterized in that, When the instructions are executed on an electronic device, the electronic device causes the electronic device to perform the method as described in any one of claims 10-15.
Citation Information
Patent Citations
Control method and device and electronic equipment
CN112882759A
Remote power-on method, electronic equipment and system
CN116074303A
