Disclosure of Invention
The technical problem to be solved by the present invention is to provide a method, an apparatus and related devices for switching multiple control centers in a home network, so as to implement switching of multiple control centers without causing service interruption.
The technical scheme adopted by the invention is that the method for switching the multiple control centers in the home network comprises the following steps of:
and when the control right is judged to be transferred to another control center, synchronizing the information of the intelligent equipment registered on the current control center to the another control center, so that the another control center can provide interactive control between the intelligent equipment and other intelligent equipment through the current control center based on the information.
Further, determining that control should be transferred to another control center includes:
when the other control center broadcasts a message, the current control center judges the priority level of the current control center and the priority level of the other control center based on a preset priority level list of the control centers;
when the priority of the current control center is lower than that of the other control center, it is determined that the control right should be transferred to the other control center.
Further, the control center priority list is preset in each control center, or preset in the intelligent device, and the control center priority list is notified to the control center when the intelligent device registers with the control center.
Further, the information of the intelligent device includes: an identification of the smart device, user data generated by the smart device on the current control center;
the control center priority list includes: control center identification and its priority information.
Further, synchronizing information of the smart device registered on the current control center to the another control center includes:
informing the other control center of the identification of the intelligent equipment registered on the current control center by registering to the other control center;
and sending the user data generated by the intelligent equipment on the current control center to the other control center.
Further, the providing, by the another control center, interactive control with other smart devices through the current control center based on the information includes:
and when the other control center provides interactive control between the intelligent equipment and other intelligent equipment, the current control center forwards messages between the intelligent equipment and the other control center.
Further, the process executed at the current control center side further includes:
stopping broadcasting the message when it is determined that the control right should be transferred to another control center;
when it is determined that control should be relinquished, interactive control with other smart devices continues to be provided for the smart device, and the broadcast message is restarted.
Further, determining that control should be regained includes:
if the broadcast message of the other control center is not received within the set time, the control right is judged to be withdrawn.
Further, the process executed at the current control center side further includes:
when receiving the information of the intelligent equipment registered on the other control center synchronized by the other control center, providing interactive control between the intelligent equipment registered on the other control center and the other intelligent equipment through the other control center based on the information synchronized by the other control center.
The invention also provides a device for switching multiple control centers in a home network, which is positioned in the current control center and comprises:
and the switching module is used for synchronizing the information of the intelligent equipment registered on the current control center to another control center when the control right is judged to be transferred to the another control center, and providing interactive control between the intelligent equipment and other intelligent equipment for the another control center through the current control center based on the information.
The invention also provides a control center in the home network, which comprises the device for switching the multiple control centers in the home network.
By adopting the technical scheme, the invention at least has the following advantages:
the method, the device and the control center for switching the multiple control centers in the home network solve the problem of how to switch the control centers when the multiple control centers exist in the home network, can realize the switching of the multiple control centers under the condition of not causing service interruption, hardly senses the switching of the control centers to an intelligent device side, and ensures the smooth operation of services.
Detailed Description
To further explain the technical means and effects of the present invention adopted to achieve the intended purpose, the present invention will be described in detail with reference to the accompanying drawings and preferred embodiments.
In a normal state, only one control center in a home network has the control right to manage the interaction among all intelligent devices, and the control center needs to broadcast messages outwards all the time to announce the existence of the control center. The current control center mentioned below in the practice of the invention refers to that control center device that actually has control right before the control center switch is made.
A first embodiment of the present invention provides a method for switching multiple control centers in a home network, as shown in fig. 1, a process executed at a current control center side includes the following specific steps:
step S101, determining whether the control right should be transferred to another control center.
Specifically, step S101 includes:
when the other control center broadcasts a message, the current control center judges the priority level of the current control center and the priority level of the other control center based on a preset priority level list of the control centers;
when the priority of the current control center is lower than that of the other control center, judging that the control right should be transferred to the other control center; otherwise, it is determined that the control right should not be transferred to another control center. At this time, for another control center, based on the idea of the technical solution in the embodiment of the present invention, when receiving the broadcast message sent by the current control center, the another control center can also know that the priority of the another control center is lower than that of the current control center, and then actively stop sending the broadcast message, and transfer or give up the control right.
Further, the control center priority list may be preset in each control center, or may also be preset in an intelligent device, and the control center priority list is notified to the control center when the intelligent device registers with the control center. The control center priority list comprises: control center identification and its priority information.
Step S102, when the control right is judged to be transferred to another control center, the information of the intelligent equipment registered on the current control center is synchronized to the another control center, so that the another control center can provide interactive control between the intelligent equipment and other intelligent equipment through the current control center based on the information. Transparent is here understood to mean transparent or forwarding.
Specifically, the information of the smart device includes: an identification of the smart device, user data generated by the smart device on the current control center;
in step S102, synchronizing information of the smart device registered in the current control center to the another control center includes:
registering with the other control center through the current control center, and informing the other control center of the identification of the intelligent equipment registered on the current control center;
and sending the user data generated by the intelligent equipment on the current control center to the other control center.
In step S102, the providing, by the other control center, interactive control with other smart devices for the smart device through the current control center based on the information includes:
and when the other control center provides interactive control between the intelligent equipment and other intelligent equipment, the current control center forwards messages between the intelligent equipment and the other control center.
A second embodiment of the present invention is a method for switching multiple control centers in a home network, which is substantially the same as the first embodiment, except that, as shown in fig. 2, in addition to step S201 corresponding to step S101 of the first embodiment, in a process executed by a current control center, step S202 further includes: when it is determined that control should be transferred to another control center, the broadcast message is stopped.
The process executed at the side of the current control center further comprises the following specific steps:
and step S203, when the control right is judged to be withdrawn, continuing to provide interactive control between the intelligent equipment and other intelligent equipment, and restarting to broadcast the message.
Preferably, in the first embodiment, the current control center further continues to store the user data generated on the smart device during the message forwarding between the smart device and the another control center, so that in this embodiment, when it is determined that the control right should be recovered, the interactive control between the smart device and the another smart device continues to be provided for the smart device.
Further, determining that control should be regained includes:
if the broadcast message of the other control center is not received within the set time, the control right is judged to be withdrawn.
Preferably, corresponding to the interactive control function completed by the other control center, the current control center may also complete the corresponding function, and therefore, in this embodiment, the process executed by the current control center side further includes:
when receiving the information of the intelligent equipment registered on the other control center synchronized by the other control center, providing interactive control between the intelligent equipment registered on the other control center and the other intelligent equipment through the other control center based on the information synchronized by the other control center.
A third embodiment of the present invention, which corresponds to the first embodiment or the second embodiment, is an apparatus for switching multiple control centers in a home network, which is located in a current control center, and as shown in fig. 3, the apparatus includes the following components:
a judging module 100, configured to judge whether the control right should be transferred to the another control center;
a switching module 200, configured to synchronize information of the smart device registered in the current control center to another control center when it is determined that the control right should be transferred to the another control center, so that the another control center provides interactive control between the smart device and another smart device through the current control center based on the information.
A fourth embodiment of the present invention, a control center in a home network, can be understood as an entity device, and the control center includes a device for switching multiple control centers in the home network described in the third embodiment.
A fifth embodiment of the present invention is based on the above embodiments, and this embodiment takes a home network including two devices with a control center function as an example, and describes an application example of the present invention with reference to fig. 4.
In the embodiment of the present invention, as shown in fig. 4, there are two control centers in the home network: the control center 1 is a home gateway, and the control center 2 is a television, but in a normal state, only one control center has an actual control right, and the control center with the control right is a real control center. The home gateway has a lower priority than the television. The device 1 and the device 2 are intelligent devices in a home network, and need to be accessed into a control center of the home network.
The flows of device registration and multi-control center switching in the home network of this embodiment are as follows:
step 1: the control center 1 sends broadcast information to announce its existence;
step 2: the device 1 is online, and a priority list of a control center is configured by a user or preset by a system on the device 1;
and step 3: the device 1 receives the broadcast message of the control center 1, and determines that the control center 1 is in the priority list of the control center and is the only control center existing in the current network;
and 4, step 4: the equipment 1 registers to the control center, and a priority list of the control center is carried in a registration message;
and 5: when the control center 2 is on line, the control center 2 starts to send broadcast messages to announce the existence of the control center;
step 6: after receiving the broadcast message of the control center 2, the control center 1 reads a locally stored priority list of the control center, and determines that the priority of the control center 2 is higher than that of the control center, so that the broadcast is stopped;
and 7: the control center 1 registers to the control center 2, and the registration information carries the information of the equipment 1;
and 8: the control center 1 sends the user data generated by the device 1 on the control center 1 to the control center 2;
and step 9: the device 2 is online, and the device 2 is configured by a user or a priority list of a control center is preset in a system;
step 10: the device 2 receives the broadcast message of the control center 2, and determines that the control center 2 is in the priority list of the control center and is the only control center existing in the current network;
step 11: the equipment 2 registers to the control center 2, and the registration message carries a priority list of the control center;
step 12: when the control center 2 is closed, the control center 1 does not receive the broadcast message of the control center 2 within the specified time, and the control center 1 starts to resend the broadcast message;
step 13: the device 2 receives the broadcast from the control center 1 and accesses the control center 1 according to the step 3.
The process of device registration and multi-control center switching in the home network of the embodiment solves the problem of how to switch the control centers when the plurality of control centers exist in the home network.
The method, the device and the control center for switching the multiple control centers in the home network can realize the switching of the multiple control centers under the condition of not causing service interruption, hardly sense the switching of the control centers to an intelligent device side, and ensure the smooth operation of services.
While the invention has been described in connection with specific embodiments thereof, it is to be understood that it is intended by the appended drawings and description that the invention may be embodied in other specific forms without departing from the spirit or scope of the invention.