State information processing method, cloud server and smart home system

By processing the status information of smart home devices according to the identification number and priority in the cloud server, the problem of low processing efficiency during peak periods is solved, and the system stability and user experience are improved.

CN118944990APending Publication Date: 2024-11-12HISENSE HOME APPLIANCES GRP CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310541405.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-05-12
Publication Date
2024-11-12

AI Technical Summary

Technical Problem

During the peak period of smart home devices, when multiple smart home devices report status information at the same time, the processing efficiency of cloud servers is low, resulting in poor system stability and poor user experience.

Method used

By receiving status information reported by smart home devices in a cloud server, using identification number and priority relationship to determine the priority of the status information set, and combining the target status information group based on the reported timestamp, determining its distribution order, and filtering not bound by the user To improve processing efficiency by specifying equipment information.

Benefits of technology

It improves the efficiency of the cloud server to process the received status information, and enhances the stability and user experience of the smart home system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118944990A_ABST
    Figure CN118944990A_ABST
Patent Text Reader

Abstract

The invention discloses a state information processing method, a cloud server and a smart home system. The method comprises the steps that the cloud server receives state information; determining the priority of each state information set according to the corresponding relationship between the identification number and the priority; identifying a report timestamp carried by each piece of state information in each state information set, and taking the state information carrying the same report timestamp as target state information to obtain at least one target state information group; and for each target state information group, determining a distribution sequence of the target state information in the target state information group according to the priority of the state information set where each piece of target state information in the target state information group is located. The cloud server determines the state information carrying the same report timestamp and determines the distribution sequence of the state information according to the priority, so that the processing efficiency of the cloud server on the received state information is improved, the stability of the smart home system is enhanced, and the user experience is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of smart home technology, and in particular to a state information processing method, a cloud server and a smart home system. Background Art

[0002] With the rapid development of smart home devices, people's lives have become more convenient and intelligent. In a smart home system, multiple smart home devices are connected to a cloud server. During the operation of multiple smart home devices, their status information will be reported to the cloud server in real time. The cloud server processes the received status information so that users can monitor and manage the smart home devices.

[0003] However, during the peak period of smart home device usage, multiple smart home devices will report a large amount of status information, causing different smart home devices to report their own status information at the same time. In this case, the cloud server has a very low efficiency in processing the received status information, and may even handle it improperly, resulting in poor stability of the smart home system and poor user experience. Summary of the invention

[0004] The present invention provides a method for processing status information, a cloud server and a smart home system, which are used to solve the problem that when multiple smart home devices report status information at the same time, the cloud server has low processing efficiency on the received status information.

[0005] In a first aspect, an embodiment of the present invention provides a method for processing status information, which is applied to a smart home system, wherein the smart home system includes a cloud server and smart home devices, and the method includes:

[0006] The cloud server receives status information reported by the smart home device, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device;

[0007] The cloud server determines the priority of each state information set according to the correspondence between the identification number and the priority, wherein the state information set corresponds to the smart home device one by one and is composed of the state information reported by the smart home device;

[0008] The cloud server identifies the reporting timestamp carried by each state information in each state information set, and uses the state information carrying the same reporting timestamp as the target state information, to obtain at least one target state information group;

[0009] For each target state information group, the cloud server determines the distribution order of the target state information in the target state information group according to the priority of the state information set to which each target state information in the target state information group belongs.

[0010] In an optional implementation, the cloud server determines the priority of each state information set according to the correspondence between the identification number and the priority, including:

[0011] The cloud server performs grouping processing on the received status information according to the identification number carried in the received status information to obtain multiple status information sets;

[0012] The cloud server determines the priority of each state information set according to the corresponding relationship between the identification number and the priority.

[0013] In an optional embodiment, the method further includes:

[0014] The cloud server distributes and processes the received status information according to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group;

[0015] The other status information is status information received by the cloud server except the target status information.

[0016] In an optional implementation, the cloud server distributes the received status information according to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried by the target status information in each target status information group, including:

[0017] The cloud server sorts the other status information and the target status information group according to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group to determine the total distribution order;

[0018] The cloud server performs distribution processing on the received status information according to the total distribution order and the distribution order of the target status information.

[0019] In an optional implementation, after the cloud server receives the status information reported by the smart home device, before determining the priority of each status information set according to the correspondence between the identification number and the priority, it also includes:

[0020] The cloud server determines the state information to be filtered from the received state information, wherein the state information to be filtered is the state information reported by the smart home device that is not bound by the user;

[0021] The cloud server deletes the status information to be filtered.

[0022] In a second aspect, an embodiment of the present invention provides a cloud server, which is applied to a smart home system, wherein the smart home system includes the cloud server and smart home devices, and the cloud server includes a memory and a processor, wherein the memory stores a computer program;

[0023] The processor is used to receive status information reported by a smart home device, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device; determine the priority of each status information set according to the corresponding relationship between the identification number and the priority, wherein the status information set corresponds to the smart home device one-to-one and is composed of the status information reported by the smart home device; identify the reporting timestamp carried by each status information in each status information set, and use the status information carrying the same reporting timestamp as the target status information to obtain at least one target status information group; for each target status information group, determine the distribution order of the target status information in the target status information group according to the priority of the status information set to which each target status information in the target status information group belongs.

[0024] In an optional implementation, the processor is specifically configured to:

[0025] According to the identification number carried in the received status information, the received status information is grouped to obtain multiple status information sets; according to the corresponding relationship between the identification number and the priority, the priority of each status information set is determined.

[0026] In an optional implementation, the processor is further configured to:

[0027] The received status information is distributed and processed according to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group; wherein the other status information is the status information received by the cloud server, except the target status information.

[0028] In an optional implementation, the processor is specifically configured to:

[0029] According to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group, the other status information and the target status information group are sorted to determine the total distribution order; according to the total distribution order and the distribution order of the target status information, the received status information is distributed and processed.

[0030] In an optional implementation, the processor is further configured to:

[0031] Determine the state information to be filtered in the received state information, wherein the state information to be filtered is the state information reported by the smart home device that is not bound by the user; and delete the state information to be filtered.

[0032] In a third aspect, an embodiment of the present invention provides a state information processing device, which is applied to a smart home system, wherein the smart home system includes a cloud server and smart home devices, and the device includes:

[0033] An information receiving module, configured to receive status information reported by a smart home device, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device;

[0034] a priority determination module, configured to determine the priority of each state information set according to the correspondence between the identification number and the priority, wherein the state information set corresponds to the smart home device one by one and is composed of the state information reported by the smart home device;

[0035] A first processing module, configured to identify a reporting timestamp carried by each state information in each state information set, and use the state information carrying the same reporting timestamp as target state information to obtain at least one target state information group;

[0036] The second processing module is used to determine, for each target state information group, a distribution order of the target state information in the target state information group according to the priority of the state information set to which each target state information in the target state information group belongs.

[0037] In an optional implementation manner, the priority determination module is specifically configured to:

[0038] According to the identification number carried in the received status information, the received status information is grouped to obtain multiple status information sets; according to the corresponding relationship between the identification number and the priority, the priority of each status information set is determined.

[0039] In an optional implementation, the device further includes an information distribution module;

[0040] The information distribution module is used to distribute and process the received status information according to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried by the target status information in each target status information group; wherein the other status information is the status information received by the cloud server, except the target status information.

[0041] In an optional implementation, the information distribution module is specifically used to:

[0042] According to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group, the other status information and the target status information group are sorted to determine the total distribution order; according to the total distribution order and the distribution order of the target status information, the received status information is distributed and processed.

[0043] In an optional implementation, the device further includes an information screening module;

[0044] The information screening module is used to determine the status information to be filtered in the received status information, wherein the status information to be filtered is the status information reported by the smart home device that is not bound by the user; and delete the status information to be filtered.

[0045] In a fourth aspect, an embodiment of the present invention provides a smart home system, including smart home devices and a cloud server, wherein:

[0046] The smart home device is used to report status information, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device;

[0047] The cloud server is used to receive status information reported by smart home devices; determine the priority of each status information set according to the corresponding relationship between the identification number and the priority, wherein the status information set corresponds to the smart home device one by one and is composed of the status information reported by the smart home device; identify the reporting timestamp carried by each status information in each status information set, and use the status information carrying the same reporting timestamp as the target status information to obtain at least one target status information group; for each target status information group, determine the distribution order of the target status information in the target status information group according to the priority of the status information set to which each target status information in the target status information group belongs.

[0048] In a fifth aspect, an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer instructions. When the computer instructions are executed on a computer, the computer executes the steps of the method for processing status information as described in any one of the embodiments in the first aspect above.

[0049] In a sixth aspect, an embodiment of the present invention provides a computer program product, including a computer program:

[0050] When the computer program is executed by a processor, the method for processing status information as described in any one of the embodiments of the first aspect above is implemented.

[0051] The technical solution provided by the embodiment of the present invention brings at least the following beneficial effects:

[0052] In the embodiment of the present invention, after the cloud server receives the status information reported by the smart home device and carrying the reporting timestamp and the identification number corresponding to the smart home device, it determines the priority of each status information set corresponding to the smart home device and composed of the status information reported by the smart home device according to the corresponding relationship between the identification number and the priority; and identifies the reporting timestamp carried by each status information in each status information set, and takes the status information carrying the same reporting timestamp as the target status information to obtain at least one target status information group; for each target status information group, according to the priority of the status information set in which each target status information in the target status information group is located, the distribution order of the target status information in the target status information group is determined. Through the above method, the cloud server determines the status information carrying the same reporting timestamp in the received status information, and determines the distribution order of the status information carrying the same reporting timestamp according to the priority, thereby improving the processing efficiency of the cloud server on the received status information, enhancing the stability of the smart home system, and improving the user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0053] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0054] Figure 1 A schematic diagram of the structure of a smart home system provided by an embodiment of the present invention;

[0055] Figure 2 A schematic diagram of the structure of a cloud server provided by an embodiment of the present invention;

[0056] Figure 3 A flowchart of a method for processing status information provided by an embodiment of the present invention;

[0057] Figure 4 A schematic diagram of the structure of a memory queue in a cloud server provided by an embodiment of the present invention;

[0058] Figure 5 A flowchart of another method for processing status information provided by an embodiment of the present invention;

[0059] Figure 6 A workflow diagram for initializing a memory queue provided by an embodiment of the present invention;

[0060] Figure 7 A schematic diagram of the structure of a cloud server provided by an embodiment of the present invention;

[0061] Figure 8 A schematic diagram of the structure of another smart home system provided by an embodiment of the present invention;

[0062] Fig. 9 A schematic diagram of the module structure of a state information processing device provided by an embodiment of the present invention;

[0063] Fig.10 A schematic diagram of a program product of a method for processing status information provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0064] In order to make the purpose, technical scheme and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0065] Furthermore, in the description of the embodiments of the present invention, unless otherwise specified, “ / ” means or. For example, A / B can mean A or B. The “and / or” in the text is merely a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present invention, “plurality” refers to two or more than two.

[0066] In the following, the terms "first" and "second" are used for descriptive purposes only and shall not be understood as suggesting or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, the features defined as "first", "second", etc. may explicitly or implicitly include one or more of the features. In the description of the embodiments of the present invention, unless otherwise specified, "plurality" means two or more.

[0067] The embodiments of the present invention provide a method for processing status information, a cloud server and a smart home system, so as to improve the processing efficiency of the cloud server on the received status information, enhance the stability of the smart home system, and improve the user experience.

[0068] A method for processing status information provided by the present invention is described below through a specific embodiment, and the method is applied to a smart home system, wherein the smart home system includes a cloud server and smart home devices. It should be noted that the smart home system in the embodiment of the present invention may include a cloud server and a smart home device, or may include a cloud server and multiple smart home devices, and the embodiment of the present invention does not impose any limitation on this.

[0069] The following embodiments are introduced with a smart home system including a cloud server and multiple smart home devices as an application scenario. Figure 1 The smart home system 10 shown includes a cloud server 101 and multiple smart home devices 102, and the multiple smart home devices 102 (smart home device 1, smart home device 2, ..., smart home device n) are respectively connected to the cloud server 101. Exemplarily, the smart home device 102 can be a smart refrigerator, a smart air conditioner, a smart TV, and other devices.

[0070] In the specific implementation, Figure 2 As shown, it is a structural diagram of a cloud server 101, which includes a message queue 21, a message listener 22, a rule engine 23, a priority queue 24, a memory queue 25, a business logic component 26 and a downstream service component 27, wherein the message queue 21, the message listener 22, the rule engine 23, the priority queue 24, the memory queue 25, the business logic component 26 and the downstream service component 27 are communicatively connected in sequence.

[0071] The purpose, features and advantages of the present invention will be further described in conjunction with the embodiments and with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.

[0072] like Figure 3 FIG. 1 is a flowchart of a method for processing status information provided by an embodiment of the present invention, and the specific steps are as follows:

[0073] Step S101: The cloud server receives status information reported by the smart home device, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device;

[0074] In the specific implementation, Figure 2As shown, the cloud server 101 receives the status information reported by the smart home device 102 in real time through the message queue 21, and temporarily stores the received status information in the message queue 21, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device 102. The cloud server 101 can obtain the time when the smart home device 102 reports the status information to the cloud server 101 by identifying the reporting timestamp carried by the status information; and can know which smart home device 102 reported the status information by identifying the identification number corresponding to the smart home device 102 carried by the status information.

[0075] It should be noted that the message queue (MQ) in the embodiment of the present invention may be KafkaMQ, Rabbit MQ, Rocket MQ, Active MQ, Zero MQ, Pulsar MQ, etc., and the embodiment of the present invention does not impose any limitation on this.

[0076] For example, if smart home device 1 uploads status information 1 to the cloud server at 9:30:22, the status information 1 received by the cloud server carries a reporting timestamp of "Time=9:30:22"; if smart home device 2 uploads status information 2 to the cloud server at 9:30:25, the status information 2 received by the cloud server carries a reporting timestamp of "Time=9:30:25". In addition, the identification number in the embodiment of the present invention can be the device ID (Identity document) of the smart home device, or it can be the WiFi ID (Wireless Fidelity Identity document) of the smart home device, and the embodiment of the present invention does not impose any limitation on this.

[0077] In a specific implementation, the cloud server 101 transmits the status information in the message queue 21 to the rule engine 23 through the message listener 22, so that the rule engine 23 processes the received status information. It should be noted that in the embodiment of the present invention, the cloud server 101 may include one message listener 22, or may include multiple message listeners 22, and the number m of message listeners 22 may be flexibly set according to actual business needs, and the embodiment of the present invention does not impose any restrictions on this.

[0078] Step S102: The cloud server determines the priority of each state information set according to the correspondence between the identification number and the priority, wherein the state information set corresponds to the smart home device one by one and is composed of the state information reported by the smart home device;

[0079] In the specific implementation, Figure 2As shown, the cloud server 101 processes the received status information through the rule engine 23 to obtain a status information set with priority, and stores the status information set in the corresponding priority queue 24 according to the priority of the status information set.

[0080] In an optional implementation, the cloud server groups the received status information according to the identification number carried in the received status information to obtain multiple status information sets; and determines the priority of each status information set according to the correspondence between the identification number and the priority.

[0081] In a specific implementation, after receiving the status information through the rule engine 23, the cloud server 101 identifies the identification number carried in the received status information, and regards the status information with the same identification number as a status information set, thereby obtaining multiple status information sets.

[0082] For example, assuming that the cloud server 101 receives 5 status information through the rule engine 24, namely: status information 1, status information 2, status information 3, status information 4 and status information 5, and recognizes that the identification numbers carried by status information 1, status information 4 and status information 5 are the same, and the identification numbers carried by status information 2 and status information 3 are the same, then status information 1, status information 4 and status information 5 are taken as status information set 1, and status information 2 and status information 3 are taken as status information set 2.

[0083] In a specific implementation, the rule engine 24 stores a correspondence between identification numbers and priorities. After obtaining multiple status information sets, the cloud server 101 determines the priority of the status information set through the rule engine 24 based on the identification number carried by the status information in each status information set and the correspondence between the identification number and the priority, and stores the status information set in the corresponding priority queue 24 according to the priority of the status information set.

[0084] Optionally, the number of priority queues 24 may be determined according to the number of smart home devices. For example, if the number of smart home devices is n, the number of priority queues 24 may be equal to n or greater than n, and this is not limited in any way in the embodiment of the present invention.

[0085] It should be noted that, in the embodiment of the present invention, the correspondence between the identification number and the priority can be determined according to the sensitivity of the smart home device, or according to the processing capability of the smart home device, and the embodiment of the present invention does not impose any limitation on this. For example, the priority corresponding to the identification number corresponding to the smart home device with high sensitivity is set higher than the priority corresponding to the identification number corresponding to the smart home device with low sensitivity, or the priority corresponding to the identification number corresponding to the smart home device with strong processing capability is set higher than the priority corresponding to the identification number corresponding to the smart home device with weak processing capability.

[0086] Exemplarily, assuming that the priority corresponding to identification number 1 is 3, the priority corresponding to identification number 2 is 2, and the priority corresponding to identification number 3 is 5, and the identification numbers carried by state information 1 and state information 5 are both identification number 1, the identification numbers carried by state information 2 and state information 3 are both identification number 3, and the identification number carried by state information 4 is identification number 2, then the priority of state information set 1 composed of state information 1 and state information 5 is 3, the priority of state information set 2 composed of state information 2 and state information 3 is 5, and the priority of state information set 3 composed of state information 4 is 2. All state information in state information set 2 is stored in priority queue 1, all state information in state information set 1 is stored in priority queue 2, and all state information in state information set 3 is stored in priority queue 3.

[0087] In an optional implementation, before the cloud server 101 performs group processing on the received status information through the rule engine 23, it can also filter the received status information, that is, determine the status information to be filtered in the received status information, wherein the status information to be filtered is the status information reported by the smart home devices that are not bound to the user; and delete the determined status information to be filtered, and retain other status information except the status information to be filtered in the status information received by the cloud server 101 through the rule engine 23.

[0088] Exemplarily, assuming that the cloud server 101 receives five status information through the rule engine 24, namely: status information 1, status information 2, status information 3, status information 4 and status information 5, the cloud server 101 identifies the identification number carried by the status information through the rule engine 24, and determines the smart home device that reports the status information according to the identification number, for example, it is determined that status information 1 and status information 4 are both reported by smart home device 1, status information 2 and status information 3 are both reported by smart home device 2, and status information 5 is reported by smart home device 3; then, the status of the smart home device is detected When the cloud server 101 detects that the smart home device is not bound by the user, the status information reported by the smart home device is used as the status information to be filtered. For example, the cloud server 101 detects that the smart home device 3 is not bound by the user, and the smart home device 1 and the smart home device 2 are both bound by the user, then the status information 5 reported by the smart home device 3 is used as the status information to be filtered; the cloud server 101 deletes the status information 5 through the rule engine 24, retains the status information 1, status information 2, status information 3 and status information 4, and uses the retained status information as the received status information for grouping processing.

[0089] In the embodiment of the present invention, the cloud server filters the received status information through a rule engine, and then groups the filtered status to filter out invalid status information reported by smart home devices that are not bound to the user, thereby reducing the processing pressure of the cloud server and improving the stability of the system.

[0090] Step S103: the cloud server identifies the reporting timestamp carried by each state information in each state information set, and uses the state information carrying the same reporting timestamp as the target state information, thereby obtaining at least one target state information group;

[0091] In a specific implementation, the cloud server 10 transmits the status information stored in the priority queue 24 to the memory queue 25 in the order of the reporting timestamps carried by the status information, and the memory queue 25 processes the received status information. Figure 4As shown, it is a schematic diagram of the structure of a memory queue 25, which includes a Producer 251, a Buffer 252 and an EventHandler 253, and the Producer 251, the Buffer 252 and the EventHandler 253 are sequentially connected in communication. Among them, the Producer 251 receives the state information transmitted through the priority queue 24, and transmits the received state information to the Buffer 252; the Buffer 252 stores the state information in the order of the timestamps carried by the received state information; the EventHandler 253 sequentially pulls the state information stored in the Buffer 252 and transmits it to the business logic component 26.

[0092] It should be noted that, in the embodiment of the present invention, the number i of Producers is related to the actual business volume or the amount of status information that the memory queue needs to process. The memory queue may include one Producer or multiple Producers, and the embodiment of the present invention does not impose any restrictions on this. The number j of EventHandlers in the embodiment of the present invention is related to the actual business volume or the amount of status information that the memory queue needs to process. The memory queue may include one EventHandler or multiple EventHandlers, and the embodiment of the present invention does not impose any restrictions on this.

[0093] Specifically, if there is state information carrying the same reporting timestamp in the state information received by the memory queue, the state information carrying the same reporting timestamp is used as the target state information to obtain at least one target state information group. Exemplarily, assuming that the reporting timestamp carried by state information 1 is "Time=9:02:35", the reporting timestamp carried by state information 2 is "Time=9:02:35", the reporting timestamp carried by state information 3 is "Time=9:02:40", the reporting timestamp carried by state information 4 is "Time=9:02:35", and the reporting timestamp carried by state information 5 is "Time=9:02:40", since the reporting timestamps carried by state information 1, state information 2, and state information 4 are the same, state information 1, state information 2, and state information 4 are used as a target state information group; since the reporting timestamps carried by state information 3 and state information 5 are the same, state information 3 and state information 5 are used as another target state information group.

[0094] Step S104: For each target state information group, the cloud server determines the distribution order of the target state information in the target state information group according to the priority of the state information set to which each target state information in the target state information group belongs.

[0095] Exemplarily, it is assumed that the state information set where state information 1 is located is state information set 1, and the priority of state information set 1 is 3; the state information set where state information 2 is located is state information set 2, and the priority of state information set 2 is 5; the state information set where state information 4 is located is state information set 3, and the priority of state information set 3 is 2; and state information 1, state information 2 and state information 4 constitute target state information group 1, then when the above state information is stored in Buffer 252, the priority of the state information set where each target state information in target state information group 1 is located is determined, that is, the priority of the state information set where state information 1, state information 2 and state information 4 are located is determined respectively; since the priority of the state information set where state information 1 is located is 3, the priority of the state information set where state information 2 is located is 5, and the priority of the state information set where state information 4 is located is 2, the target state information in the target state information group is sorted according to the size of the priority, and the distribution order of the target state information in the target state information group is obtained, that is, the distribution order of the target state information in the target state information group 1 is: state information 2, state information 1, state information 4.

[0096] In the embodiment of the present invention, after the cloud server receives the status information reported by the smart home device and carrying the reporting timestamp and the identification number corresponding to the smart home device, it determines the priority of each status information set corresponding to the smart home device and composed of the status information reported by the smart home device according to the corresponding relationship between the identification number and the priority; and identifies the reporting timestamp carried by each status information in each status information set, and takes the status information carrying the same reporting timestamp as the target status information to obtain at least one target status information group; for each target status information group, according to the priority of the status information set in which each target status information in the target status information group is located, the distribution order of the target status information in the target status information group is determined. Through the above method, the cloud server determines the status information carrying the same reporting timestamp in the received status information, and determines the distribution order of the status information carrying the same reporting timestamp according to the priority, thereby improving the processing efficiency of the cloud server on the received status information, enhancing the stability of the smart home system, and improving the user experience.

[0097] In an optional embodiment, if Figure 5 As shown, the method further comprises the following steps:

[0098] Step S501: The cloud server sorts other state information and target state information groups according to the order of the reporting timestamps carried in each other state information and the reporting timestamps carried in the target state information in each target state information group, and determines the total distribution order; wherein the other state information is the state information received by the cloud server, except the target state information;

[0099] In a specific implementation, the cloud server determines the status information with the same reporting timestamp as the target status information based on the reporting timestamp carried by the status information, and uses the determined target status information as the target status information group; and sorts the other status information and the target status information group in the order of the reporting timestamps to determine the total distribution order; then for each target status information group, the cloud server sorts the target status information in the target status information group according to the priority of the status information set in which the target status information in the target status information group is located, and determines the distribution order of the target status information in the target status information group.

[0100] Exemplarily, assume that the status information received by the cloud server through the memory queue is: status information 1, status information 2, status information 3, status information 4, status information 5 and status information 6, wherein the reporting timestamp carried by status information 1 is "Time=9:02:30", the reporting timestamps carried by status information 2, status information 3 and status information 5 are all "Time=9:02:33", the reporting timestamp carried by status information 4 is "Time=9:02:35", and the reporting timestamp carried by status information 6 is "Time=9:02:40", then status information 2, status information 3 and status information 5 constitute target status information group 1, and according to the order of the reporting timestamps corresponding to status information 1, status information 4, status information 6 and target status information group 1, the total distribution order is determined to be: status information 1, target status information group 1, status information 4, status information 6. For target status information group 1, according to the priority of the status information set where status information 2, status information 3 and status information 5 are located, the distribution order of the status information in target status information group 1 is determined as: status information 2, status information 5, status information 3.

[0101] Step S502: The cloud server distributes the received status information according to the total distribution order and the distribution order of the target status information.

[0102] In a specific implementation, the cloud server determines the distribution order of all received status information in combination with the total distribution order and the distribution order of the target status information in the target status information group, and distributes the status information according to the distribution order.

[0103] Exemplarily, if the total distribution order determined by the cloud server is: status information 1, target status information group 1, status information 4, status information 6, and the distribution order of the status information in the target status information group 1 is determined to be: status information 2, status information 5, status information 3, then the distribution order of the status information received by the cloud server is: status information 1, status information 2, status information 5, status information 3, status information 4, status information 6, and the status information is stored in Buffer 252 according to this distribution order.

[0104] In a specific implementation, Buffer 252 includes Sequence (queue) and available Sequence (available queue), wherein the position in Sequence and the position in available Sequence are set in one-to-one correspondence. Specifically, before Producer 251 sends status information to Buffer 252, it is necessary to apply for multiple empty storage positions in Sequence of Buffer 252. After receiving the status information, Buffer 252 sorts it and stores the status information in the multiple storage positions applied for in Sequence according to the distribution order. For example, if status information 1 is stored in storage position 1 in Sequence, the corresponding position in available Sequence needs to be set, that is, position 1 in available Sequence is set to indicate that storage position 1 is occupied, thereby completing the storage of a status information.

[0105] In a specific implementation, EventHandler 253 includes a poller, EventHandler 253 polls Sequences, and sequentially pulls state information stored in Sequences to business logic component 26, so that business logic component 26 processes the state information.

[0106] Optionally, when the cloud server is powered on, the memory queue needs to be initialized, such as Figure 6 As shown, the specific workflow for initializing the memory queue is as follows:

[0107] Step S601: The cloud server is powered on and starts initializing the memory queue;

[0108] Step S602: determine the capacity of the buffer in the memory queue;

[0109] In a specific implementation, the capacity of the Buffer in the memory queue can be set according to actual business needs. For example, the capacity of the Buffer can be set to 1024×1024.

[0110] Step S603, determining the number of EventHandlers in the memory queue and the triggering rules of EventHandlers;

[0111] In a specific implementation, the number of EventHandlers in the memory queue can be set according to actual business needs. For example, if the current business needs are large, the number of EventHandlers can be set to 20. If the current business needs are small, the number of EventHandlers can be set to 10. The embodiment of the present invention does not impose any restrictions on this. And the trigger rules are configured for the EventHandler in the memory queue. When the polling device in the EventHandler polls the status information corresponding to the trigger rule in the Buffer, the status information is pulled.

[0112] For example, the triggering rule of EventHandler can be configured according to the WiFi ID corresponding to the smart home device in the smart home system. For example, a hash operation is performed on the WiFi ID corresponding to the smart home device, and the modulus of the hash operation result is taken according to the determined number of EventHandlers to obtain a triggering rule. If the number of EventHandlers is set to j=10, the triggering rule is: hashCode(WiFi ID)%10.

[0113] Step S604: Initialize the memory queue according to the determined Buffer capacity, the number of EventHandlers and the triggering rule of EventHandler;

[0114] Step S605, end initialization.

[0115] It should be noted that, in the embodiment of the present invention, the number of EventHandlers can be adjusted according to the amount of status information processed by the cloud server. When the cloud server processes a large amount of status information, the number of EventHandlers can be increased to expand the processing capacity of the cloud server so that the cloud server can process massive amounts of status information; when the cloud server processes a small amount of status information, the number of EventHandlers can be reduced to shrink the processing capacity of the cloud server and save system resources.

[0116] In a specific implementation, since the device status contained in the status information is usually ciphertext, after receiving the status information, the business logic component 26 decrypts the status information and transmits the decrypted status information to the downstream service component 27, so that the downstream service component 27 responds to the status information. Exemplarily, the downstream service component 27 may be an alarm service, which triggers an alarm notification according to changes in the status information after receiving the status information; or, the downstream service component 27 may be a scene service, which triggers a specific scene according to changes in the status information after receiving the status information.

[0117] Based on the same concept, an embodiment of the present invention further provides a cloud server, which is applied to a smart home system. The smart home system includes a cloud server and smart home devices. Since the cloud server is the cloud server in the method in the embodiment of the present invention, and the principle of solving the problem by the cloud server is similar to that of the method, the implementation of the cloud server can refer to the implementation of the method, and the repeated parts will not be repeated.

[0118] Refer to the following Figure 7 To describe the cloud server 70 according to this embodiment of the present invention. Figure 7 The cloud server 70 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.

[0119] like Figure 7 As shown, the cloud server 70 can be in the form of a general computing device, for example, it can be a terminal device. The components of the cloud server 70 can include but are not limited to: the at least one processor 71 mentioned above, and the at least one memory 72 storing executable instructions of the processor 71, and the processor 71 is a processor of a smart device.

[0120] The processor 71 implements the following steps by running the executable instructions:

[0121] Receive status information reported by a smart home device, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device; determine the priority of each status information set according to the corresponding relationship between the identification number and the priority, wherein the status information set corresponds to the smart home device one-to-one and is composed of status information reported by the smart home device; identify the reporting timestamp carried by each status information in each status information set, and use the status information carrying the same reporting timestamp as the target status information to obtain at least one target status information group; for each target status information group, determine the distribution order of the target status information in the target status information group according to the priority of the status information set to which each target status information in the target status information group belongs.

[0122] In an optional implementation manner, the processor 71 is specifically configured to:

[0123] According to the identification number carried in the received status information, the received status information is grouped to obtain multiple status information sets; according to the corresponding relationship between the identification number and the priority, the priority of each status information set is determined.

[0124] In an optional implementation, the processor 71 is further configured to:

[0125] The received status information is distributed and processed according to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group; wherein the other status information is the status information received by the cloud server except the target status information.

[0126] In an optional implementation manner, the processor 71 is specifically configured to:

[0127] According to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group, the other status information and the target status information group are sorted to determine the total distribution order; according to the total distribution order and the distribution order of the target status information, the received status information is distributed and processed.

[0128] In an optional implementation, the processor 71 is further configured to:

[0129] Determine the state information to be filtered from the received state information, wherein the state information to be filtered is the state information reported by the smart home device that is not bound by the user; and delete the state information to be filtered.

[0130] Based on the same concept, an embodiment of the present invention further provides a smart home system, which includes smart home devices and a cloud server. Since the cloud server is the cloud server in the method in the embodiment of the present invention, and the principle of solving the problem by the cloud server is similar to that of the method, the implementation of the cloud server can refer to the implementation of the method, and the repeated parts will not be repeated.

[0131] like Figure 8 As shown, the smart home system 80 includes a smart home device 81 and a cloud server 82, wherein:

[0132] A smart home device 81, used to report status information, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device 81;

[0133] The cloud server 82 is used to receive the status information reported by the smart home device 81; determine the priority of each status information set according to the corresponding relationship between the identification number and the priority, wherein the status information set corresponds to the smart home device 81 one by one and is composed of the status information reported by the smart home device 81; identify the reporting timestamp carried by each status information in each status information set, and use the status information carrying the same reporting timestamp as the target status information to obtain at least one target status information group; for each target status information group, determine the distribution order of the target status information in the target status information group according to the priority of the status information set to which each target status information in the target status information group belongs.

[0134] Based on the same concept, an embodiment of the present invention also provides a status information processing device, which is applied to a smart home system. The smart home system includes a cloud server and smart home devices. Since the device is the device in the method in the embodiment of the present invention, and the principle of solving the problem by the device is similar to that of the method, the implementation of the device can refer to the implementation of the method, and the repeated parts will not be repeated.

[0135] like Fig. 9 As shown, the above device includes the following modules:

[0136] The information receiving module 901 is used to receive the status information reported by the smart home device, wherein the status information carries the reporting timestamp and the identification number corresponding to the smart home device;

[0137] A priority determination module 902, configured to determine the priority of each state information set according to the correspondence between the identification number and the priority, wherein the state information set corresponds to the smart home device one by one and is composed of the state information reported by the smart home device;

[0138] The first processing module 903 is used to identify the reporting timestamp carried by each state information in each state information set, and use the state information carrying the same reporting timestamp as the target state information to obtain at least one target state information group;

[0139] The second processing module 904 is used to determine, for each target state information group, a distribution order of the target state information in the target state information group according to the priority of the state information set to which each target state information in the target state information group belongs.

[0140] In an optional implementation, the priority determination module 902 is specifically configured to:

[0141] According to the identification number carried in the received status information, the received status information is grouped to obtain multiple status information sets; according to the corresponding relationship between the identification number and the priority, the priority of each status information set is determined.

[0142] In an optional implementation, the above device further includes an information distribution module;

[0143] The information distribution module is used to distribute and process the received status information according to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried by the target status information in each target status information group; wherein the other status information is the status information received by the cloud server, except the target status information.

[0144] In an optional implementation, the information distribution module is specifically used to:

[0145] According to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group, the other status information and the target status information group are sorted to determine the total distribution order; according to the total distribution order and the distribution order of the target status information, the received status information is distributed and processed.

[0146] In an optional implementation, the above device further includes an information screening module;

[0147] The information screening module is used to determine the status information to be filtered in the received status information, wherein the status information to be filtered is the status information reported by the smart home device that is not bound by the user; and delete the status information to be filtered.

[0148] In some possible implementations, various aspects of the present invention may also be implemented in the form of a program product, which includes a program code. When the program product runs on a terminal device, the program code is used to enable the terminal device to execute the steps of each module in the state information processing device according to various exemplary implementations of the present disclosure described in the above "Exemplary Method" section of this specification, for example, receiving state information reported by a smart home device, wherein the state information carries a reporting timestamp and an identification number corresponding to the smart home device; determining the priority of each state information set according to the corresponding relationship between the identification number and the priority, wherein the state information set corresponds to the smart home device one-to-one and is composed of the state information reported by the smart home device; identifying the reporting timestamp carried by each state information in each state information set, and taking the state information carrying the same reporting timestamp as the target state information to obtain at least one target state information group; for each target state information group, determining the distribution order of the target state information in the target state information group according to the priority of the state information set in which each target state information in the target state information group is located.

[0149] like Fig.10As shown, a program product 100 of a method for processing status information according to an embodiment of the present invention is described, which can adopt a portable compact disk read-only memory (CD-ROM) and include program code, and can be run on a terminal device, such as a personal computer. However, the program product of the present invention is not limited thereto. In this document, a readable storage medium can be any tangible medium containing or storing a program, which can be used by or in combination with an instruction execution system, an apparatus or a device.

[0150] The present application is described above with reference to the block diagrams and / or flow charts showing the methods, devices (systems) and / or computer program products according to the embodiments of the present application. It should be understood that a block of the block diagram and / or flow chart diagram and a combination of blocks of the block diagram and / or flow chart diagram can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer and / or other programmable data processing device to produce a machine, so that the instructions executed by the computer processor and / or other programmable data processing device create a method for implementing the functions / actions specified in the block diagram and / or flow chart block.

[0151] Accordingly, the present application may also be implemented with hardware and / or software (including firmware, resident software, microcode, etc.). Furthermore, the present application may take the form of a computer program product on a computer-usable or computer-readable storage medium, which has a computer-usable or computer-readable program code implemented in the medium, for use by an instruction execution system or in conjunction with an instruction execution system. In the context of the present application, a computer-usable or computer-readable medium may be any medium that may contain, store, communicate, transmit, or convey a program for use by an instruction execution system, device, or apparatus, or in conjunction with an instruction execution system, device, or apparatus.

[0152] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims

1. A method for processing status information, characterized in that: Applied to a smart home system, the smart home system includes a cloud server and smart home devices, and the method includes: The cloud server receives status information reported by the smart home device, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device; The cloud server determines the priority of each state information set according to the correspondence between the identification number and the priority, wherein the state information set corresponds to the smart home device one by one and is composed of the state information reported by the smart home device; The cloud server identifies the reporting timestamp carried by each state information in each state information set, and uses the state information carrying the same reporting timestamp as the target state information, to obtain at least one target state information group; For each target state information group, the cloud server determines the distribution order of the target state information in the target state information group according to the priority of the state information set to which each target state information in the target state information group belongs.

2. The method according to claim 1, characterized in that The cloud server determines the priority of each state information set according to the corresponding relationship between the identification number and the priority, including: The cloud server performs grouping processing on the received status information according to the identification number carried in the received status information to obtain multiple status information sets; The cloud server determines the priority of each state information set according to the corresponding relationship between the identification number and the priority.

3. The method according to claim 1, characterized in that The method further comprises: The cloud server distributes and processes the received status information according to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group; The other status information is status information received by the cloud server except the target status information.

4. The method according to claim 3, characterized in that The cloud server distributes and processes the received status information according to the order of the reporting timestamps carried in each other status information and the reporting timestamps carried in the target status information in each target status information group, including: The cloud server sorts the other status information and the target status information group according to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group to determine the total distribution order; The cloud server performs distribution processing on the received status information according to the total distribution order and the distribution order of the target status information.

5. The method according to any one of claims 1 to 4, characterized in that: After the cloud server receives the status information reported by the smart home device, before determining the priority of each status information set according to the corresponding relationship between the identification number and the priority, the method further includes: The cloud server determines the state information to be filtered from the received state information, wherein the state information to be filtered is the state information reported by the smart home device that is not bound by the user; The cloud server deletes the status information to be filtered.

6. A cloud server, characterized in that: Applied to a smart home system, the smart home system comprises the cloud server and smart home devices, the cloud server comprises a memory and a processor, the memory stores a computer program; The processor is used to receive status information reported by a smart home device, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device; determine the priority of each status information set according to the corresponding relationship between the identification number and the priority, wherein the status information set corresponds to the smart home device one-to-one and is composed of the status information reported by the smart home device; identify the reporting timestamp carried by each status information in each status information set, and use the status information carrying the same reporting timestamp as the target status information to obtain at least one target status information group; for each target status information group, determine the distribution order of the target status information in the target status information group according to the priority of the status information set to which each target status information in the target status information group belongs.

7. The cloud server according to claim 6, wherein: The processor is further configured to: Distribute and process the received status information according to the order of the reporting timestamp carried in each other status information and the reporting timestamp carried in the target status information in each target status information group; The other status information is status information received by the cloud server except the target status information.

8. The cloud server according to claim 7, wherein: The processor is specifically used for: According to the order of the reporting timestamps carried in each other state information and the reporting timestamps carried in the target state information in each target state information group, the other state information and the target state information group are sorted to determine the total distribution order; The received status information is distributed and processed according to the total distribution order and the distribution order of the target status information.

9. A device for processing status information, characterized in that: Applied to a smart home system, the smart home system includes a cloud server and smart home devices, and the device includes: An information receiving module, configured to receive status information reported by a smart home device, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device; a priority determination module, configured to determine the priority of each state information set according to the correspondence between the identification number and the priority, wherein the state information set corresponds to the smart home device one by one and is composed of the state information reported by the smart home device; A first processing module, configured to identify a reporting timestamp carried by each state information in each state information set, and use the state information carrying the same reporting timestamp as target state information to obtain at least one target state information group; The second processing module is used to determine, for each target state information group, a distribution order of the target state information in the target state information group according to the priority of the state information set to which each target state information in the target state information group belongs.

10. A smart home system, characterized in that: Includes smart home devices and cloud servers, including: The smart home device is used to report status information, wherein the status information carries a reporting timestamp and an identification number corresponding to the smart home device; The cloud server is used to receive status information reported by the smart home device; determine the priority of each status information set according to the corresponding relationship between the identification number and the priority, wherein the status information set corresponds to the smart home device one by one and is composed of the status information reported by the smart home device; Identify the reporting timestamp carried by each state information in each state information set, and use the state information carrying the same reporting timestamp as the target state information to obtain at least one target state information group; for each target state information group, determine the distribution order of the target state information in the target state information group according to the priority of the state information set to which each target state information in the target state information group belongs.