Patent ID: 12210484

DETAILED DESCRIPTION OF THE EMBODIMENTS

In order to make objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be described in detail below. It is apparent that the described embodiments are only part of the embodiments of this application, not all the embodiments. All other implementations obtained by those of ordinary skill in the art on the basis of the embodiments in this application without creative work all fall within the scope of protection of this application.

FIG.1is a flowchart of a method for establishing a scene according to an exemplary embodiment of this application. As shown inFIG.1, the method includes the following steps:S101, current state information of all devices in a target folder sent by a terminal is received, and the target folder is a set of devices that support scene establishment;S102, a target scene is established according to the current state information;S103, state information corresponding to the target scene is sent to the terminal, and the state information corresponding to the target scene is locally pre-stored according to user demands.

In an embodiment, after the state information corresponding to the target scene is sent to the terminal, the method further includes: a request sent by the terminal to delete the target scene is received, wherein the request carries an empty target folder; and on a basis of the empty target folder, the state information corresponding to the target scene is deleted.

FIG.2is a flowchart of a method for establishing a scene according to an exemplary embodiment of this application. As shown inFIG.2, the method includes the following steps:S201, at least two or more devices are put into a target folder is detected;S202, current state information corresponding to the at least two or more devices is sent to a server;S203, state information corresponding to a target scene which is established by the server according to the current state information of the at least two or more devices is received.

In an embodiment, after the state information corresponding to the target scene which is established by the server according to the current state information of the at least two or more devices is received, the method further includes: according to the state information corresponding to the target scene, the at least two or more devices are controlled to adjust to a state corresponding to the state information from a current state.

In some embodiments, a control process is triggered by means of clicking a device icon of the terminal on a page.

In an embodiment, after the state information corresponding to the target scene which is established by the server according to the current state information of the at least two or more devices are received, the method further includes: a name of the target folder that is displayed on the terminal is updated, and the name is synchronized to the server.

In some embodiments, an update operation is started by means of pressing the target folder for a bit longer.

In an embodiment, after the state information corresponding to the target scene which is established by the server according to the current state information of the at least two or more devices is received, the method further includes: a third device is put into the target folder is detected; current state information corresponding to all devices of the target folder is sent to the server; and state information corresponding to the target scene which is updated by the server according to the current state information corresponding to all the devices is received.

In an embodiment, after the state information corresponding to the target scene which is established by the server according to the current state information of the at least two or more devices is received, the method further includes: a request of deleting the target scene is received; the target folder is emptied on a basis of the request; and an empty target folder is sent to the server.

In some embodiments, a deleting operation is started by means of pressing the target folder for a bit longer.

To sum up, in this application, a scene is established by means of a simple user operation interaction method. An Application (App) on the terminal may automatically send the current state of a device to the server; the device is dragged to execute the scene; the device is clicked to execute the corresponding scene; and the device is pressed for a bit longer to enter a scene-editing mode. The above method is in line with the interaction habits of existing users, such that a learning threshold of the users is lowered, and the scene is rapidly established, thereby improving user experience of the smart home device.

The embodiments of this application are described and illustrated below with reference to specific examples.

FIG.3is a schematic diagram of a process for establishing a scene according to an embodiment of this application. As shown inFIG.3, the process includes two parts, which respectively are a user interaction process and a technology realization process. Conditions required for the above processes include: 1) a network is configured for the device; and 2) the connection state of the device is normal.

The user interaction process and the technology realization process are introduced below in detail.

The user interaction process:1. A user is on a home furnishing page of an App on a terminal.2. The home furnishing page of the App includes two or more devices that support a scene.3. The user drags small device cards (device icons), so as to cause the two small cards to coincide.4. A big card similar to a “folder” is newly added to the home furnishing page, two devices that are just dragged by the user are newly added to the big card, but the original positions of the two devices are not changed.5. After the big card is established successfully, the App sends the states of the devices when the user drags and establishes a scene to a server, then the server automatically establishes the scene, and the current device mode is an action required to be executed after the scene is triggered.6. The user may edit the name of the scene, and the App synchronizes the name of the scene to the server.7. The user clicks the big card, then the App provides a scene triggering signal to the server, and the server sends instructions to the devices in batches to execute the action under the scene.8. The user may enter a scene-editing page by pressing the big card for a bit longer, so as to edit the current modes of the devices, or may set a delayed trigger scene.

The technology realization process:1. The small device cards daily query the states of the devices in turn every 8 s and synchronize the states.2. When the user drags the small cards to form the big card, the App sends the states of all the devices in the big card to the server.3. The server establishes the scene according to the states of the devices sent by the App.4. On the basis of the existing big card, if the user newly drags a device into the big card, the App sends the modes of all the devices in the big card to the server again.5. The server updates the devices and modes under the scene.6. If the user selects “Delete all devices” and performs saving when editing the scene, the App shows that the scene has been deleted; the App sends the devices and modes (actually, there is no device) under the scene to the server; then the server deletes the scene after updating the deleted devices and modes.

This embodiment further provides an apparatus for establishing a scene. The apparatus is configured to implement the foregoing embodiments and the preferred implementation, and what has been described will not be described again. As used below, the terms “module”, “unit”, “sub-unit” and the like may be a combination of software and/or hardware that implements a predetermined function. Although the apparatus described in the following embodiments is preferably implemented in software, but implementations in hardware, or a combination of software and hardware, are also possible and conceived.

FIG.4is a schematic diagram of an apparatus for establishing a scene according to an exemplary embodiment of this application. As shown inFIG.4, the apparatus includes:a first receiving unit40, configured to receive current state information of all devices in a target folder sent by a terminal. The target folder is a set of devices that support scene establishment;an establishment unit41, configured to establish a target scene according to the current state information;a first sending unit42, configured to send state information corresponding to the target scene to the terminal. The state information corresponding to the target scene is locally pre-stored according to user demands.

In an embodiment, the first sending unit42is further configured, after sending the state information corresponding to the target scene to the terminal, to receive a request sent by the terminal to delete the target scene, where the request carries an empty target folder; and on a basis of the empty target folder, delete the state information corresponding to the target scene.

FIG.5is a schematic diagram of an apparatus for establishing a scene according to an exemplary embodiment of this application. As shown inFIG.5, the apparatus includes:a detection unit50, configured to detect that at least two or more devices are put into a target folder;a second sending unit51, configured to send current state information corresponding to the at least two or more devices to a server;a second receiving unit52, configured to receive state information corresponding to a target scene which is established by the server according to the current state information of the at least two or more devices.

In an embodiment, the second receiving unit52is further configured, after receiving the state information corresponding to the target scene which is established by the server according to the current state information of the at least two or more devices, to control, according to the state information corresponding to the target scene, the at least two or more devices to adjust to a state corresponding to the state information from a current state.

In an embodiment, the second receiving unit52is further configured, after receiving the state information corresponding to the target scene which is established by the server according to the current state information of the at least two or more devices, to update a name of the target folder that is displayed on a terminal, and synchronize the name to the server.

In an embodiment, the second receiving unit52is further configured, after receiving the state information corresponding to the target scene which is established by the server according to the current state information of the at least two or more devices, to detect that a third device is put into the target folder; send current state information corresponding to all devices of the target folder to the server; and receive state information corresponding to the target scene which is updated by the server according to the current state information corresponding to all the devices.

In an embodiment, the second receiving unit52is further configured, after receiving the state information corresponding to the target scene which is established by the server according to the current state information of the at least two or more devices, to receive a request of deleting the target scene; empty the target folder on the basis of the request; and send an empty target folder to the server.

It is to be noted that, each of the above modules may be either functional modules or program modules, and may be implemented either by means of software or hardware. For the modules implemented by means of the hardware, the modules may be located in the same processor; or the modules may also be located in different processors in any combination.

An embodiment of this application further provides a computer device. The method for establishing the scene in the embodiments of this application may be implemented by means of the computer device. The computer device in this embodiment of this application includes a memory, a processor and a computer program that is stored on the memory and executable on the processor. The processor, when executing the computer program, implements any one of the methods for establishing the scene described in the above embodiments.

An embodiment of this application further provides a computer-readable storage medium. The computer-readable storage medium stores a computer program instruction. Any one of the methods for establishing scene described in the above embodiments is implemented when the computer program instruction is executed by a processor.

It is understandable that the same or similar parts of the above embodiments may be referred to each other, and those not specified in some embodiments may be referred to the same or similar contents in other embodiments.

It is to be noted that, in the description of this application, the terms “first”, “second” and the like are for descriptive purposes only, and should not be construed as indicating or implying relative importance. In addition, in the description of this application, “a plurality of” or “more” means at least two, unless otherwise specified.

It should be understood that, when one element is “fixed to” or “disposed on” the other element, the element may be directly on the other element or intermediate elements may be exist at the same time; when one element is “connected to” the other element, the element may be directly connected to the other element or intermediate elements may be exist at the same time; furthermore, “connected” as used herein may include wirelessly connected; and the word “and/or” as used includes any and all combinations of one or more of associated listed items.

Any process or method in the flowcharts or described herein in another manner may be understood to represent a module, segment or part including codes of one or more executable instructions configured to realize specific logic functions or steps of the process and, moreover, the scope of the preferred implementation mode of this application includes other implementation, not in a sequence shown or discussed herein, including execution of the functions basically simultaneously or in an opposite sequence according to the involved functions. This should be understood by those skilled in the art of the embodiments of this application.

It should be understood that, each part of this application may be implemented by hardware, software, firmware or a combination thereof. In the above embodiments, a plurality of steps or methods may be implemented by software or firmware stored in a memory and executed by a proper instruction execution system. For example, in case of implementation with the hardware, like another implementation, any one or combination of the following technologies well-known in the art may be adopted for implementation: a discrete logic circuit with a logic gate circuit configured to realize a logic function for a data signal, an application-specific integrated circuit with a proper combined logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA) and the like.

Those of ordinary skill in the art may understand that all or part of the steps in the above method embodiments may be implemented by a program to instruct related hardware, and the program may be stored in a computer-readable storage medium. When the program is executed, one of the steps of the method embodiments or a combination thereof is included.

In addition, the functional units in the various embodiments of this application may be integrated into one processing module, or each unit may exist alone physically, or two or more than two units may be integrated into one module. The above integrated module may be implemented in a form of hardware, or may be implemented in a form of a software functional module. If the integrated module is implemented in the form of the software functional module and sold or used as an independent product, it may be stored in the computer readable storage medium.

The foregoing storage medium may be an ROM, a magnetic disk, or an optical disk.

In the description of the specification, descriptions of the terms “an embodiment,” “some embodiments,” “example,” “specific example,” or “some examples”, mean that specific features, structures, materials, or characteristics described with reference to the implementations or examples are included in at least one implementation or example of this application. In this specification, schematic representations of the above terms do not necessarily refer to the same embodiment or example. In addition, the described particular features, structures, materials or characteristics may be combined in any suitable manner in any one or more embodiments or examples.

Although the embodiments of this application are shown and described above, it is understandable that the above embodiments are exemplary and not to be construed as limitations of the present application, and those of ordinary skill in the art may make changes, modifications, replacements and variations of the above embodiments within the scope of this application.