CN106933111B - Method and device for controlling equipment - Google Patents
Method and device for controlling equipment Download PDFInfo
- Publication number
- CN106933111B CN106933111B CN201710116598.4A CN201710116598A CN106933111B CN 106933111 B CN106933111 B CN 106933111B CN 201710116598 A CN201710116598 A CN 201710116598A CN 106933111 B CN106933111 B CN 106933111B
- Authority
- CN
- China
- Prior art keywords
- key
- identifier
- control command
- equipment
- user
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05B—CONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
- G05B15/00—Systems controlled by a computer
- G05B15/02—Systems controlled by a computer electric
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05B—CONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
- G05B19/00—Programme-control systems
- G05B19/02—Programme-control systems electric
- G05B19/418—Total factory control, i.e. centrally controlling a plurality of machines, e.g. direct or distributed numerical control [DNC], flexible manufacturing systems [FMS], integrated manufacturing systems [IMS] or computer integrated manufacturing [CIM]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04M—TELEPHONIC COMMUNICATION
- H04M1/00—Substation equipment, e.g. for use by subscribers
- H04M1/72—Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
- H04M1/724—User interfaces specially adapted for cordless or mobile telephones
- H04M1/72403—User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
- H04M1/72409—User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality by interfacing with external accessories
- H04M1/72415—User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality by interfacing with external accessories for remote control of appliances
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05B—CONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
- G05B2219/00—Program-control systems
- G05B2219/20—Pc systems
- G05B2219/26—Pc applications
- G05B2219/2642—Domotique, domestic, home control, automation, smart house
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02P—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
- Y02P90/00—Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
- Y02P90/02—Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]
Landscapes
- Engineering & Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Automation & Control Theory (AREA)
- Human Computer Interaction (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Manufacturing & Machinery (AREA)
- Quality & Reliability (AREA)
- Selective Calling Equipment (AREA)
- Telephonic Communication Services (AREA)
Abstract
The disclosure relates to a method and a device for controlling equipment, and belongs to the field of communication. The method comprises the following steps: acquiring a key identifier of each key in at least one key pressed by a terminal in a screen locking state, and forming the key identifier of each key into a first key identifier set; acquiring a corresponding device identifier and a corresponding control command from the key identifier set, the device identifier and the corresponding control command according to the first key identifier set; and sending the control command to the equipment corresponding to the equipment identifier according to the equipment identifier so as to control the equipment to execute the operation corresponding to the control command. The device comprises a first acquisition module, a second acquisition module and a sending module. The present disclosure can improve the efficiency of the control device.
Description
Technical Field
The present disclosure relates to the field of communications, and in particular, to a method and an apparatus for controlling a device.
Background
With the development of smart home services, a plurality of smart home devices are currently available, and users can control the smart home devices by using mobile terminals such as mobile phones for the convenience of using the smart home devices. For example, a user can use a mobile phone to control a smart lamp at home to turn on or off, and the like.
In the related technology, a user wants to control a device on a mobile phone, firstly, the mobile phone is opened, and a client for controlling the device is found in the mobile phone; then starting the client and opening a control interface for controlling the equipment in the client, wherein the control interface comprises all control commands for controlling the equipment; finally, the user can select a certain control command, and the mobile terminal sends the control command selected by the user to the equipment so as to enable the equipment to execute the control command selected by the user.
Disclosure of Invention
In order to improve the efficiency of control equipment, the embodiment of the disclosure provides a method and a device for controlling equipment. The technical scheme is as follows:
according to a first aspect of embodiments of the present disclosure, there is provided a method of controlling a device, the method comprising:
acquiring a key identifier of each key in at least one key pressed by a terminal in a screen locking state, and forming the key identifier of each key into a first key identifier set;
acquiring a corresponding device identifier and a corresponding control command from the key identifier set, the device identifier and the corresponding control command according to the first key identifier set;
and sending the control command to the equipment corresponding to the equipment identifier according to the equipment identifier so as to control the equipment to execute the operation corresponding to the control command.
Optionally, the obtaining, according to the first key identifier set, the corresponding device identifier and the control command from the corresponding relationship between the key identifier set, the device identifier, and the control command includes:
sending an inquiry request message to a server, wherein the inquiry request message carries a user account and the first key identifier set, and the inquiry request message is used for the server to acquire a corresponding device identifier and a corresponding control command from a key identifier set corresponding to the user account, a corresponding relationship between the device identifier and the control command according to the first key identifier set;
and receiving a query response message sent by the server, wherein the query response message carries the equipment identifier and the control command acquired by the server.
Optionally, the method further includes:
acquiring an equipment identifier and a control command selected by a user, acquiring a key identifier of each key in at least one key pressed by a terminal and forming a second key identifier set;
and correspondingly storing the second key identification set, the equipment identification selected by the user and the control command in the corresponding relation among the key identification set, the equipment identification and the control command.
Optionally, before acquiring the device identifier and the control command selected by the user, the method further includes:
acquiring a user account, and acquiring a device identifier of a device bound with the user account and a control command included by the device;
and displaying the equipment identification of the equipment bound with the user account and the control command included by the equipment.
Optionally, the obtaining the device identifier of the device bound to the user account and the control command included in the device includes:
acquiring and displaying the equipment identifier and the equipment type of the equipment bound with the user account;
acquiring the equipment identification and the equipment type of equipment selected by a user;
and acquiring and displaying a control command included in the equipment selected by the user according to the equipment type of the equipment selected by the user.
According to a second aspect of embodiments of the present disclosure, there is provided an apparatus for controlling a device, the apparatus comprising:
the terminal comprises a first obtaining module, a second obtaining module and a third obtaining module, wherein the first obtaining module is configured to obtain a key identifier of each key in at least one key pressed by the terminal in a screen locking state and form the key identifier of each key into a first key identifier set;
the second obtaining module is configured to obtain corresponding equipment identifiers and control commands from the corresponding relations among the key identifier sets, the equipment identifiers and the control commands according to the first key identifier set;
and the sending module is configured to send the control command to the device corresponding to the device identifier according to the device identifier so as to control the device to execute the operation corresponding to the control command.
Optionally, the second module includes:
a sending unit, configured to send an inquiry request message to a server, where the inquiry request message carries a user account and the first key identifier set, and the inquiry request message is used for the server to obtain, according to the first key identifier set, a corresponding device identifier and a corresponding control command from a key identifier set corresponding to the user account, a corresponding relationship between the device identifier and the control command;
and the receiving unit is used for receiving a query response message sent by the server, wherein the query response message carries the equipment identifier and the control command acquired by the server.
Optionally, the apparatus further comprises:
the third acquisition module is configured to acquire the device identifier and the control command selected by the user, acquire the key identifier of each key in at least one key pressed by the terminal and form a second key identifier set;
and the storage module is configured to correspondingly store the second key identification set, the device identification selected by the user and the control command in the corresponding relation among the key identification set, the device identification and the control command.
Optionally, the apparatus further comprises:
the fourth acquisition module is configured to acquire a user account, and acquire a device identifier of a device bound with the user account and a control command included in the device;
a display module configured to display the device identifier of the device bound to the user account and a control command included in the device.
Optionally, the fourth obtaining module includes:
the acquisition display unit is used for acquiring and displaying the equipment identifier and the equipment type of the equipment bound with the user account;
the device comprises an acquisition unit, a storage unit and a processing unit, wherein the acquisition unit is used for acquiring the device identification and the device type of the device selected by a user; and acquiring and displaying a control command included in the equipment selected by the user according to the equipment type of the equipment selected by the user.
According to a third aspect of the embodiments of the present disclosure, there is provided an apparatus for controlling a device, including:
a processor;
a memory for storing executable instructions of the processor;
wherein the processor is configured to:
acquiring a key identifier of each key in at least one key pressed by a terminal in a screen locking state, and forming the key identifier of each key into a first key identifier set;
acquiring a corresponding device identifier and a corresponding control command from the key identifier set, the device identifier and the corresponding control command according to the first key identifier set;
and sending the control command to the equipment corresponding to the equipment identifier according to the equipment identifier so as to control the equipment to execute the operation corresponding to the control command.
The technical scheme provided by the embodiment of the disclosure can have the following beneficial effects:
when the terminal is in a screen locking state, each key identification in at least one key pressed on the terminal by a user is obtained and forms a key identification set, corresponding equipment to be controlled and a control command are obtained according to the key identification set, and the control command is sent to the equipment, so that the equipment executes the operation corresponding to the control command.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure.
FIG. 1 is a flow chart illustrating a method of controlling a device according to an exemplary embodiment;
FIG. 2-1 is a flow diagram illustrating a correspondence of a set of configuration key identifications, device identifications, and control commands in accordance with another exemplary embodiment;
2-2 are schematic diagrams of a device selection interface according to another exemplary embodiment;
2-3 are schematic diagrams of a command selection interface according to another exemplary embodiment;
FIG. 3 is a flow chart illustrating a method of controlling a device according to another exemplary embodiment;
FIG. 4-1 is a block diagram illustrating an apparatus for controlling a device according to an exemplary embodiment;
FIG. 4-2 is a block diagram illustrating a second acquisition module, according to an exemplary embodiment;
4-3 are block diagrams illustrating an apparatus for controlling a device according to another exemplary embodiment;
4-4 are block diagrams illustrating an apparatus for controlling a device according to another exemplary embodiment;
FIGS. 4-5 are block diagrams illustrating a fourth acquisition module according to an exemplary embodiment;
FIG. 5 is a block diagram illustrating an apparatus to control a device according to an exemplary embodiment.
With the foregoing drawings in mind, certain embodiments of the disclosure have been shown and described in more detail below. These drawings and written description are not intended to limit the scope of the disclosed concepts in any way, but rather to illustrate the concepts of the disclosure to those skilled in the art by reference to specific embodiments.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
FIG. 1 is a flow chart illustrating a method of controlling a device according to an exemplary embodiment, which may include the steps of:
in step 101: the method comprises the steps of obtaining the key identification of each key in at least one key pressed by the terminal in a screen locking state, and forming a first key identification set by the key identification of each key.
In step 102: and acquiring the corresponding equipment identifier and the control command from the corresponding relation among the key identifier set, the equipment identifier and the control command according to the first key identifier set.
In step 103: and sending the control command to the equipment corresponding to the equipment identifier according to the equipment identifier so as to control the equipment to execute the operation corresponding to the control command.
The terminal can be a mobile terminal such as a mobile phone or a tablet computer.
In this embodiment, when the terminal is in the screen locking state, the user directly presses at least one key on the terminal, the terminal acquires the at least one key, acquires the device and the control command which need to be controlled in the user family according to the at least one key, and sends the control command to the device, so that the device executes the operation corresponding to the control command.
A user uses a terminal to control equipment in a family, and needs to configure a key identification set, a corresponding relation between equipment identification and a control command, and then control the equipment in the family to execute operation through the corresponding relation between the key identification set, the equipment identification and the control command. Wherein, the correspondence relationship between the key identification set and the device identification and the control command can be configured through the flow shown in the following fig. 2-1, and the devices in the family can be controlled to execute the operation through the flow shown in the following fig. 3.
Referring to fig. 2-1, an embodiment of the present disclosure provides a process for configuring a corresponding relationship between a key identifier set, an equipment identifier and a control command, where an execution subject of the process may be a mobile terminal such as a mobile phone or a tablet computer, and the process includes:
in step 201: and acquiring the equipment identification and the equipment type of each equipment bound with the user account according to the user account.
The step is to enable a user to configure at least one key on the terminal for controlling a certain device in a family to execute an operation corresponding to a certain control command. For example, for a smart light bulb, a user may configure a volume up key on the terminal for controlling the smart light bulb to increase brightness and a volume down key on the terminal for controlling the smart light bulb to decrease brightness.
When configuring, a user needs to input a user account to a terminal first, so that the terminal can obtain device identifications and device types of devices included in a user family according to the user account. The method comprises the following steps:
a terminal acquires a user account provided by a user and sends an acquisition request to a server, wherein the acquisition request carries the user account; the server receives the acquisition request, acquires the equipment identification and the equipment type of each equipment bound with the user account from the corresponding relation among the user account, the equipment identification and the equipment type according to the user account carried by the acquisition request, and sends an acquisition response to the terminal, wherein the acquisition response carries the equipment identification and the equipment type of each equipment bound with the user account; and the terminal receives the acquisition response and extracts the equipment identification and the equipment type of each equipment bound with the user account from the acquisition response.
For each device in the user's home, the user may bind the device with its user account in the server in advance, and the binding process may be:
for the device needing to be bound, the user can input a user account and a binding instruction to the device; the device receives the binding instruction and the user account, acquires a device identifier and a device type of the device, and sends a binding request to a server, wherein the binding request carries the user account, the device identifier and the device type of the device; and the server receives the binding request, and correspondingly stores the user account, the equipment identifier and the equipment type carried by the binding request in the corresponding relation among the user account, the equipment identifier and the equipment type.
In step 202: and acquiring the equipment identifier and the control command selected by the user, acquiring the key identifier of each key in at least one key pressed by the terminal, and forming the key identifier of each key into a second key identifier set.
In this step: the terminal can display the equipment identification and the equipment type of each equipment bound with the user account to the user so that the user can select the equipment identification and the equipment type of the equipment needing to be configured; the terminal acquires the equipment identification and the equipment type of the equipment selected by the user, acquires each control command included in the equipment selected by the user according to the equipment type of the equipment selected by the user, displays the acquired control commands to enable the user to select the control command, and acquires the control command selected by the user; and when detecting that at least one key on the terminal is pressed, acquiring the key identification of each key in the at least one key and forming the key identification of each key into a second key identification set.
The configuration file can be stored locally in the terminal or on the server, and is used for storing the corresponding relation between the device type and the control command. The configuration file may be configured by a device manufacturer, and the device manufacturer may store the device type of the device and the control command correspondence included in the device in the configuration file each time the device manufacturer designs a new type of device, and then update the configuration file stored in the server with the configuration file. Also the terminal can obtain the configuration file from the server and update the locally stored configuration file.
In actual implementation, the terminal may display a device selection interface, where the device selection interface includes device identifiers and device types of devices bound to the user account, and the user may select the device identifier and the device type of one device in the device selection interface. The terminal inquires out each control command included by the equipment selected by the user from the configuration file stored locally or the configuration file stored by the server according to the equipment type selected by the user; displaying a command selection interface, wherein the command selection interface comprises the equipment identifier of the equipment selected by the user and each control command included by the equipment selected by the user; the user can select a control command in the command selection interface, and the terminal obtains the control command selected by the user. The user can press at least one key on the terminal after selecting the control command, correspondingly, when the terminal detects that the at least one key is pressed, the key identification of each key in the at least one key is obtained, and the key identification of each key is formed into a second key identification set.
For example, assume that the devices bound to the user account include a smart light bulb, a smart television, and a smart refrigerator, the device identification of the smart light bulb is TID1, the device type is a light bulb, the device identification of the smart television is TID2, the device type is a television, and the device identification of the smart refrigerator is TID3, and the device type is a refrigerator. The terminal displays a device selection interface as shown in fig. 2-2, which includes the device identification TID1 and the device type "light bulb" of the smart light bulb, the device identification TID2 and the device type "television" of the smart television, and the device identification TID3 and the device type "refrigerator" of the smart refrigerator.
The user then selects the device identification TID1 and the device type "light bulb" of the smart light bulb in the device selection interface as shown in fig. 2-2. The terminal obtains the device identification TID1 and the device type "light bulb" of the smart light bulb from the device selection interface as shown in fig. 2-2, obtains the control command of the smart light bulb according to the device type "light bulb", and displays the obtained control command on the command selection interface as shown in fig. 2-3, assuming that the control command includes an increase command for increasing the brightness, a decrease command for decreasing the brightness, an on command for turning on the light bulb, and an off command for turning off the light bulb. The user may select a control command in the command selection interface as shown in fig. 2-3, assuming an increase command is selected; the terminal obtains the add command from the command selection interface shown in fig. 2-3, and obtains the key identifier of the pressed key when detecting that the user presses the key of the terminal, assuming that the user presses the volume increase key and the key identifier of the volume increase key is EID1, i.e. the key identifier is EID1 and constitutes a second key identifier set.
In step 203: and correspondingly storing the second key identification set, the equipment identification selected by the user and the control command in the corresponding relation among the key identification set, the equipment identification and the control command.
The corresponding relation between the key identification set, the equipment identification and the control command can be stored in the local terminal or the server. When the corresponding relation between the key identification set, the equipment identification and the control command is stored in the server, the user can control the equipment through different terminals.
And when the corresponding relation among the key identification set, the equipment identification and the control command is stored in the server, the terminal sends a storage request to the server, wherein the storage request carries the user account, the second key identification set, the equipment identification selected by the user and the control command. The server receives the storage request, acquires a corresponding relation between a key identification set, an equipment identification and a control command corresponding to the user account according to the user account carried by the storage request, and then correspondingly stores a second key identification set, an equipment identification and a control command carried by the storage request in the corresponding relation between the key identification set, the equipment identification and the control command corresponding to the user account.
For example, the terminal may store the second set of key identifications EID1, device identification TID1, and add command correspondence in the key identification set, device identification, and control command correspondence as shown in table 1.
TABLE 1
Key label set | Device identification | Control command |
EID1 | TID1 | Add command |
…… | …… | …… |
After the user has configured at least one key corresponding to one device, the user may continue to configure keys corresponding to other devices in the manner described above. After the configuration is finished, the device may be controlled using the correspondence between the set of key identifiers, the device identifier, and the control command. The detailed control process can be referred to the flow shown in fig. 3.
Referring to fig. 3, fig. 3 is a flowchart of a method for controlling a device according to an embodiment of the present disclosure, where an execution subject of the flowchart may be a mobile terminal such as a mobile phone or a tablet computer, and the method includes:
in step 301: and determining whether the terminal is in a screen locking state, and if so, executing step 302.
Since the terminal is in the lock screen state, the user does not need to use the keys on the terminal to control the terminal itself, so that the keys of the terminal in the lock screen state can be defined to be used for controlling the devices in the user's home.
In step 302: the method comprises the steps of obtaining the key identification of each key in at least one key pressed by a terminal and forming a first key identification set by the key identification of each key.
When a user wants to control a certain device to execute a certain control command, the user can press the device and at least one key on the terminal corresponding to the control command when the terminal is in a screen locking state. Correspondingly, the terminal acquires the key identification of each key in at least one key pressed by the user.
For example, if the user wants to control the smart light bulb to perform an operation of increasing the brightness corresponding to the increase command, the user may press a volume increase key on the terminal while the terminal is in the screen lock state. The terminal acquires the key identification EID1 of the volume increasing key pressed by the user and forms a first key identification set.
In step 303: and acquiring the corresponding equipment identifier and the control command from the corresponding relation among the key identifier set, the equipment identifier and the control command according to the first key identifier set.
When the corresponding relation among the key identification set, the equipment identification and the control command is stored locally in the terminal, the terminal directly obtains the corresponding equipment identification and the control command from the locally stored corresponding relation among the key identification set, the equipment identification and the control command according to the first key identification set.
When the corresponding relation between the key identification set, the equipment identification and the control command is stored in the server, the terminal can acquire a user account and send a query request message to the server, wherein the query request message carries the user account and the first key identification set; the server receives the query request message, and acquires a key identification set corresponding to a user account, a device identification and a corresponding relation of a control command according to the user account carried by the query request message; acquiring a corresponding device identifier and a corresponding control command from a key identifier set corresponding to the user account, a corresponding relation between the device identifier and the control command according to a first key identifier set carried by the query request message, and sending a query response message to the terminal, wherein the query response message carries the acquired device identifier and the control command; and the terminal receives the query response message sent by the server and extracts the equipment identification and the control command carried by the query response message.
For example, assuming that the correspondence between the key identifier sets and the device identifiers and the control commands shown in table 1 is stored locally in the terminal, the terminal may combine the obtained key identifiers EID1 of the volume up keys into a first key identifier set, and according to the first key identifier set, obtain the corresponding device identifiers "TID 1" and the control commands "up commands" from the correspondence between the key identifier sets and the device identifiers and the control commands shown in table 1.
In step 304: and sending the control command to the equipment corresponding to the equipment identifier according to the equipment identifier so as to control the equipment to execute the operation corresponding to the control command.
For example, an increase command is sent to the smart bulb according to the device identification TID1, and the smart bulb receives the increase command and increases its light emission brightness according to the increase command.
In this embodiment, when the terminal is in a screen locking state, each key identifier of at least one key pressed by a user on the terminal is acquired and constitutes a key identifier set, a corresponding device to be controlled and a control command are acquired according to the key identifier set, and the control command is sent to the device, so that the device executes an operation corresponding to the control command.
The following are embodiments of the disclosed apparatus that may be used to perform embodiments of the disclosed methods. For details not disclosed in the embodiments of the apparatus of the present disclosure, refer to the embodiments of the method of the present disclosure.
Fig. 4-1 is a block diagram illustrating an apparatus 400 for controlling a device according to an example embodiment, where the apparatus 400 may be implemented as part or all of a terminal through software, hardware, or a combination of both. The apparatus 400 may include:
the first obtaining module 401 is configured to obtain a key identifier of each key of at least one key that is pressed by the terminal in the screen lock state, and form the key identifier of each key into a first key identifier set.
A second obtaining module 402, configured to obtain, according to the first key identifier set, a corresponding device identifier and a corresponding control command from the key identifier set, the device identifier, and the corresponding control command.
A sending module 403, configured to send the control command to a device corresponding to the device identifier according to the device identifier, so as to control the device to execute an operation corresponding to the control command.
Optionally, referring to fig. 4-2, the second module 402 includes:
a sending unit 4021, configured to send a query request message to a server, where the query request message carries a user account and the first key identifier set, and the query request message is used by the server to obtain, according to the first key identifier set, a corresponding device identifier and a corresponding control command from a key identifier set corresponding to the user account, a corresponding relationship between the device identifier and the control command;
a receiving unit 4022, configured to receive an inquiry response message sent by the server, where the inquiry response message carries the device identifier and the control command acquired by the server.
Optionally, referring to fig. 4-3, the apparatus 400 further comprises:
a third obtaining module 404, configured to obtain the device identifier and the control command selected by the user, and obtain a key identifier of each key of the at least one key pressed by the terminal and form a second key identifier set;
a saving module 405 configured to correspondingly save the second set of key identifiers, the device identifier selected by the user, and the control command in a corresponding relationship among the set of key identifiers, the device identifier, and the control command.
Optionally, referring to fig. 4-4, the apparatus 400 further comprises:
a fourth obtaining module 406, configured to obtain a user account, and obtain a device identifier of a device bound to the user account and a control command included in the device;
a display module 407 configured to display the device identifier of the device bound to the user account and the control command included in the device.
Optionally, referring to fig. 4 to 5, the fourth obtaining module 406 includes:
the obtaining and displaying unit 4061 is configured to obtain and display the device identifier and the device type of the device bound to the user account;
an obtaining unit 4062, configured to obtain an apparatus identifier and an apparatus type of an apparatus selected by a user; and acquiring and displaying a control command included in the equipment selected by the user according to the equipment type of the equipment selected by the user.
In this embodiment, when the terminal is in a screen locking state, each key identifier of at least one key pressed by a user on the terminal is acquired and constitutes a key identifier set, a corresponding device to be controlled and a control command are acquired according to the key identifier set, and the control command is sent to the device, so that the device executes an operation corresponding to the control command.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
Fig. 5 is a block diagram illustrating an apparatus 500 for controlling a device according to an example embodiment. For example, the apparatus 500 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, and the like.
Referring to fig. 5, the apparatus 500 may include one or more of the following components: processing component 502, memory 504, power component 506, multimedia component 508, audio component 510, input/output (I/O) interface 512, sensor component 514, and communication component 516.
The processing component 502 generally controls overall operation of the device 500, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing components 502 may include one or more processors 520 to execute instructions to perform all or a portion of the steps of the methods described above. Further, the processing component 502 can include one or more modules that facilitate interaction between the processing component 502 and other components. For example, the processing component 502 can include a multimedia module to facilitate interaction between the multimedia component 508 and the processing component 502.
The memory 504 is configured to store various types of data to support operations at the apparatus 500. Examples of such data include instructions for any application or method operating on device 500, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 504 may be implemented by any type or combination of volatile or non-volatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
The power supply component 506 provides power to the various components of the device 500. The power components 506 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the apparatus 500.
The multimedia component 508 includes a screen that provides an output interface between the device 500 and the user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 508 includes a front facing camera and/or a rear facing camera. The front camera and/or the rear camera may receive external multimedia data when the device 500 is in an operating mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
The audio component 510 is configured to output and/or input audio signals. For example, audio component 510 includes a Microphone (MIC) configured to receive external audio signals when apparatus 500 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may further be stored in the memory 504 or transmitted via the communication component 516. In some embodiments, audio component 510 further includes a speaker for outputting audio signals.
The I/O interface 512 provides an interface between the processing component 502 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: a home button, a volume button, a start button, and a lock button.
The sensor assembly 514 includes one or more sensors for providing various aspects of status assessment for the device 500. For example, the sensor assembly 514 may detect an open/closed state of the apparatus 500, the relative positioning of the components, such as a display and keypad of the apparatus 500, the sensor assembly 514 may also detect a change in the position of the apparatus 500 or a component of the apparatus 500, the presence or absence of user contact with the apparatus 500, orientation or acceleration/deceleration of the apparatus 500, and a change in the temperature of the apparatus 500. The sensor assembly 514 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 514 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 514 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 516 is configured to facilitate communication between the apparatus 500 and other devices in a wired or wireless manner. The apparatus 500 may access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 516 receives a broadcast signal or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 516 further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the apparatus 500 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, micro-controllers, microprocessors or other electronic components for performing the above-described methods.
In an exemplary embodiment, a non-transitory computer-readable storage medium comprising instructions, such as the memory 504 comprising instructions, executable by the processor 520 of the apparatus 500 to perform the above-described method is also provided. For example, the non-transitory computer readable storage medium may be a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
A non-transitory computer readable storage medium having instructions therein which, when executed by a processor of an apparatus 500, enable the apparatus 500 to perform a method of controlling a device, the method comprising:
acquiring a key identifier of each key in at least one key pressed by a terminal in a screen locking state, and forming the key identifier of each key into a first key identifier set;
acquiring a corresponding device identifier and a corresponding control command from the key identifier set, the device identifier and the corresponding control command according to the first key identifier set;
and sending the control command to the equipment corresponding to the equipment identifier according to the equipment identifier so as to control the equipment to execute the operation corresponding to the control command.
Optionally, the obtaining, according to the first key identifier set, the corresponding device identifier and the control command from the corresponding relationship between the key identifier set, the device identifier, and the control command includes:
sending an inquiry request message to a server, wherein the inquiry request message carries a user account and the first key identifier set, and the inquiry request message is used for the server to acquire a corresponding device identifier and a corresponding control command from a key identifier set corresponding to the user account, a corresponding relationship between the device identifier and the control command according to the first key identifier set;
and receiving a query response message sent by the server, wherein the query response message carries the equipment identifier and the control command acquired by the server.
Optionally, the method further includes:
acquiring an equipment identifier and a control command selected by a user, acquiring a key identifier of each key in at least one key pressed by a terminal and forming a second key identifier set;
and correspondingly storing the second key identification set, the equipment identification selected by the user and the control command in the corresponding relation among the key identification set, the equipment identification and the control command.
Optionally, before acquiring the device identifier and the control command selected by the user, the method further includes:
acquiring a user account, and acquiring a device identifier of a device bound with the user account and a control command included by the device;
and displaying the equipment identification of the equipment bound with the user account and the control command included by the equipment.
Optionally, the obtaining the device identifier of the device bound to the user account and the control command included in the device includes:
acquiring and displaying the equipment identifier and the equipment type of the equipment bound with the user account;
acquiring the equipment identification and the equipment type of equipment selected by a user;
and acquiring and displaying a control command included in the equipment selected by the user according to the equipment type of the equipment selected by the user.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.
Claims (5)
1. A method of controlling a device, the method comprising:
acquiring a key identifier of each key in at least one key pressed by a terminal in a screen locking state, and forming the key identifier of each key into a first key identifier set; acquiring a corresponding device identifier and a corresponding control command from the key identifier set, the device identifier and the corresponding control command according to the first key identifier set; according to the equipment identification, sending the control command to equipment corresponding to the equipment identification so as to control the equipment to execute the operation corresponding to the control command;
the method further comprises the following steps:
acquiring a user account input by a user, and sending an acquisition request to a server, wherein the acquisition request carries the user account; receiving an acquisition response sent by the server, and displaying a device identifier and a device type of a device bound with the user account, which are carried in the acquisition response, wherein the device identifier and the device type of the device bound with the user account are determined by the server from corresponding relations among stored user accounts, device identifiers and device types based on the user account, the corresponding relations among the stored user accounts, the stored device identifiers and the stored device types are established by the server based on a received binding request, the binding request is sent to the server by the device receiving the user account and a binding instruction, and the binding request carries the user account, the device identifier and the device type of the device;
acquiring the equipment identifier and the equipment type of the equipment selected by the user, and acquiring at least one control command of the equipment selected by the user according to the equipment identifier and the equipment type of the equipment selected by the user; acquiring and displaying a control command of the equipment selected by the user, acquiring a key identifier of each key in at least one key pressed by the terminal and forming a second key identifier set; and correspondingly storing the second key identification set, the equipment identification selected by the user and the control command in the corresponding relation among the key identification set, the equipment identification and the control command.
2. The method of claim 1, wherein obtaining the corresponding device identifier and control command from the correspondence between the key identifier set, the device identifier and the control command according to the first key identifier set comprises:
sending a query request message to a server, wherein the query request message carries the user account and the first key identifier set, and the query request message is used for the server to acquire a corresponding device identifier and a corresponding control command from a key identifier set corresponding to the user account, a corresponding relationship between the device identifier and the control command according to the first key identifier set;
and receiving a query response message sent by the server, wherein the query response message carries the equipment identifier and the control command acquired by the server.
3. An apparatus for controlling a device, the apparatus comprising:
the terminal comprises a first obtaining module, a second obtaining module and a third obtaining module, wherein the first obtaining module is configured to obtain a key identifier of each key in at least one key pressed by the terminal in a screen locking state and form the key identifier of each key into a first key identifier set;
the second obtaining module is configured to obtain corresponding equipment identifiers and control commands from the corresponding relations among the key identifier sets, the equipment identifiers and the control commands according to the first key identifier set;
the sending module is configured to send the control command to the device corresponding to the device identifier according to the device identifier, so as to control the device to execute an operation corresponding to the control command;
the device further comprises:
the third acquisition module is configured to acquire the device identifier and the control command selected by the user, acquire the key identifier of each key in at least one key pressed by the terminal and form a second key identifier set;
the storage module is configured to correspondingly store the second key identification set, the device identification selected by the user and the control command in a corresponding relation among the key identification set, the device identification and the control command;
the device further comprises:
a fourth obtaining module, configured to obtain a user account input by the user, and obtain a device identifier of a device bound to the user account and a control command included in the device;
a display module configured to display a device identifier of the device bound to the user account and a control command included in the device;
the fourth obtaining module includes:
the acquisition display unit is used for sending an acquisition request to a server, wherein the acquisition request carries the user account; receiving an acquisition response sent by the server; displaying the device identification and the device type of the device bound with the user account, which are carried in the acquisition response, wherein the device identification and the device type of the device bound with the user account are determined by the server based on the user account from the corresponding relation among the stored user account, the stored device identification and the stored device type, which is established by the server based on the received binding request, the binding request is sent to the server by the device receiving the user account and the binding instruction, and the binding request carries the user account and the device identification and the device type of the device;
an obtaining unit, configured to obtain a device identifier and a device type of the device selected by the user; acquiring at least one control command of the equipment selected by the user according to the equipment identification and the equipment type of the equipment selected by the user; and acquiring and displaying a control command included in the equipment selected by the user.
4. The apparatus of claim 3, wherein the second obtaining module comprises:
a sending unit, configured to send an inquiry request message to a server, where the inquiry request message carries the user account and the first key identifier set, and the inquiry request message is used for the server to obtain, according to the first key identifier set, a corresponding device identifier and a corresponding control command from a key identifier set corresponding to the user account, a corresponding relationship between the device identifier and the control command;
and the receiving unit is used for receiving a query response message sent by the server, wherein the query response message carries the equipment identifier and the control command acquired by the server.
5. An apparatus for controlling a device, comprising:
a processor;
a memory for storing executable instructions of the processor;
wherein the processor is configured to:
acquiring a key identifier of each key in at least one key pressed by a terminal in a screen locking state, and forming the key identifier of each key into a first key identifier set;
acquiring a corresponding device identifier and a corresponding control command from the key identifier set, the device identifier and the corresponding control command according to the first key identifier set;
according to the equipment identification, sending the control command to equipment corresponding to the equipment identification so as to control the equipment to execute the operation corresponding to the control command;
the processor is further configured to:
acquiring a user account input by a user, and sending an acquisition request to a server, wherein the acquisition request carries the user account; receiving an acquisition response sent by the server, and displaying a device identifier and a device type of a device bound with the user account, which are carried in the acquisition response, wherein the device identifier and the device type of the device bound with the user account are determined by the server from corresponding relations among stored user accounts, device identifiers and device types based on the user account, the corresponding relations among the stored user accounts, the stored device identifiers and the stored device types are established by the server based on a received binding request, the binding request is sent to the server by the device receiving the user account and a binding instruction, and the binding request carries the user account, the device identifier and the device type of the device;
acquiring the equipment identifier and the equipment type of the equipment selected by the user, and acquiring at least one control command of the equipment selected by the user according to the equipment identifier and the equipment type of the equipment selected by the user; acquiring and displaying a control command of the equipment selected by the user, acquiring a key identifier of each key in at least one key pressed by the terminal and forming a second key identifier set;
and correspondingly storing the second key identification set, the equipment identification selected by the user and the control command in the corresponding relation among the key identification set, the equipment identification and the control command.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710116598.4A CN106933111B (en) | 2017-02-28 | 2017-02-28 | Method and device for controlling equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710116598.4A CN106933111B (en) | 2017-02-28 | 2017-02-28 | Method and device for controlling equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106933111A CN106933111A (en) | 2017-07-07 |
CN106933111B true CN106933111B (en) | 2020-10-30 |
Family
ID=59423948
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710116598.4A Active CN106933111B (en) | 2017-02-28 | 2017-02-28 | Method and device for controlling equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106933111B (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107995355B (en) * | 2017-11-08 | 2020-10-16 | 浙江凯耀照明股份有限公司 | Quick and simple method for controlling light by mobile phone |
CN108494580B (en) * | 2018-02-07 | 2022-02-25 | 海尔优家智能科技(北京)有限公司 | Method, medium, terminal and device for updating device information |
CN110196671B (en) * | 2018-02-27 | 2021-05-25 | 杭州海康威视数字技术股份有限公司 | Equipment management method, device and system |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103312526A (en) * | 2012-03-07 | 2013-09-18 | 施耐德电气东南亚(总部)有限公司 | Binding and pairing method, control system and control equipment |
CN104111727A (en) * | 2014-06-24 | 2014-10-22 | 联想(北京)有限公司 | Information processing method and electronic equipment |
CN104346100A (en) * | 2014-10-17 | 2015-02-11 | 广东欧珀移动通信有限公司 | A shortcut operation method and device for an intelligent mobile terminal in a black screen state |
CN104503688A (en) * | 2014-12-31 | 2015-04-08 | 小米科技有限责任公司 | Method and device for realizing control of intelligent hardware equipment |
CN106303004A (en) * | 2016-08-04 | 2017-01-04 | 北京奇虎科技有限公司 | The way of recording, device and mobile terminal under screen lock state |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150159893A1 (en) * | 2013-12-11 | 2015-06-11 | International Business Machines Corporation | Intelligent thermostat control system |
US20150370272A1 (en) * | 2014-06-23 | 2015-12-24 | Google Inc. | Intelligent configuration of a smart environment based on arrival time |
-
2017
- 2017-02-28 CN CN201710116598.4A patent/CN106933111B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103312526A (en) * | 2012-03-07 | 2013-09-18 | 施耐德电气东南亚(总部)有限公司 | Binding and pairing method, control system and control equipment |
CN104111727A (en) * | 2014-06-24 | 2014-10-22 | 联想(北京)有限公司 | Information processing method and electronic equipment |
CN104346100A (en) * | 2014-10-17 | 2015-02-11 | 广东欧珀移动通信有限公司 | A shortcut operation method and device for an intelligent mobile terminal in a black screen state |
CN104503688A (en) * | 2014-12-31 | 2015-04-08 | 小米科技有限责任公司 | Method and device for realizing control of intelligent hardware equipment |
CN106303004A (en) * | 2016-08-04 | 2017-01-04 | 北京奇虎科技有限公司 | The way of recording, device and mobile terminal under screen lock state |
Also Published As
Publication number | Publication date |
---|---|
CN106933111A (en) | 2017-07-07 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP3136793B1 (en) | Method and apparatus for awakening electronic device | |
CN104407592B (en) | A kind of method and device adjusting smart home device operating status | |
CN107608561B (en) | Touch screen control method and device | |
CN108810866B (en) | Method and device for connecting intelligent equipment and storage medium | |
CN107102772B (en) | Touch control method and device | |
CN104834665A (en) | Target picture acquiring method and device | |
WO2020097845A1 (en) | Method and device for using network slice | |
CN109525966B (en) | Intelligent device query method and device and storage medium | |
CN106507282B (en) | Wireless connection control method and device | |
US20220256497A1 (en) | Methods and apparatuses for receiving paging signaling, and methods and apparatuses for transmitting paging signaling | |
CN109324846B (en) | Application display method and device and storage medium | |
CN107197441A (en) | The operating mode control method and device of intelligent home device | |
CN104539789A (en) | Method and device for prompting call request | |
CN103986821A (en) | Method, equipment and system for carrying out parameter adjustment | |
CN110262692B (en) | Touch screen scanning method, device and medium | |
CN105281994A (en) | Working mode switching method and device | |
CN107220059B (en) | Application interface display method and device | |
CN106292316B (en) | Working mode switching method and device | |
CN106296775B (en) | Icon generation method and device | |
CN111277984A (en) | Wireless local area network access method and device | |
CN106933111B (en) | Method and device for controlling equipment | |
CN107463372B (en) | Data-driven page updating method and device | |
CN104951522B (en) | Method and device for searching | |
CN115499438A (en) | A task allocation method, device, electronic equipment and storage medium | |
CN107846646B (en) | Control method and device of intelligent sound box and readable storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |