Device control method, storage medium and electronic device
By displaying and adjusting device control conditions and instructions in the configuration page, combined with asynchronous or non-asynchronous callback processor calls, the efficiency of device function adjustment is improved, and the problem of low efficiency of device function adjustment in the prior art is solved.
Patent Information
- Application Number
- CN202210590987.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-27
- Publication Date
- 2024-12-20
- Estimated Expiration
- 2042-05-27
AI Technical Summary
In the prior art, the efficiency of implementing device function adjustment through code is low, and this problem cannot be effectively solved.
Provides a device control method, displays multiple configuration options by displaying a configuration page, including control conditions, control instructions and device information, responds to configuration adjustment requests, adjusts target control conditions and instructions, and configures the response information of the controlled device based on these conditions. , processor calls using asynchronous or non-asynchronous callbacks to improve efficiency.
By adjusting the device functions in the configuration page, the time consumption is significantly shortened, efficiency is improved, and the problem of low efficiency in the code to adjust the device functions is solved.
Smart Images

Figure CN115032917B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communications, and in particular to a device control method, a storage medium, and an electronic device. Background Art
[0002] At present, after a device is manufactured, it is usually necessary to adjust one or more functions in the device. For example, after an air conditioner is manufactured, it is desired to adjust the voice control function of the air conditioner.
[0003] In the related art, when adjusting the function of a device, developers usually adjust the code to adjust the function of the device. However, adjusting the function of the device through code is time-consuming and inefficient.
[0004] In the related technology, due to the low efficiency of adjusting the function of the device through code, no effective solution has been proposed yet. Summary of the invention
[0005] The embodiments of the present invention provide a device control method, a storage medium and an electronic device to at least solve the technical problem in the related art that the efficiency of device function adjustment is relatively low due to code implementation.
[0006] According to an embodiment of the present invention, there is provided a device control method, comprising: displaying a configuration page, wherein a plurality of configuration options are displayed on the configuration page, each of the configuration options corresponds to at least one of a control condition, a control instruction, device information and a reply information, the control condition is used to trigger the corresponding control instruction, the control instruction is used to control the controlled device to perform a corresponding action, the device information is used to indicate the state of the controlled device, and the reply information is used for the controlled device to respond to a request instruction of a target user; in response to a configuration adjustment request triggered by a target configuration option displayed on the configuration page, adjusting a target control condition and / or a target control instruction corresponding to the target configuration option; and configuring target reply information of the target controlled device based on the target control condition and / or the target control instruction.
[0007] In an exemplary embodiment, after configuring the target reply information of the target controlled device based on the target control condition and / or target control instruction, the method includes: receiving the first control request instruction and the second control request instruction uploaded by the target controlled device; parsing the first control request instruction to determine the first target control condition and / or the first target control instruction corresponding to the first control request instruction; parsing the second control request instruction to determine the second target control condition and / or the second target control instruction corresponding to the second control request instruction; and when the first target control condition and the second target control condition are mutually exclusive or the first target control instruction and the second target control instruction are mutually exclusive, sending the first target reply information to the target controlled device, wherein the first target reply information is used to indicate that the target controlled device has failed to respond.
[0008] In an exemplary embodiment, after configuring the target reply information of the target controlled device based on the target control condition and / or the target control instruction, it includes: receiving a third control request instruction uploaded by the target controlled device; parsing the third control request instruction to determine whether the third control request instruction corresponds to a third target control condition and / or a third target control instruction; if the third control request instruction does not correspond to the third target control condition and / or the third target control instruction, sending a second target reply information to the target controlled device, wherein the second target reply information is used to determine the third target control condition and / or the third target control instruction.
[0009] In an exemplary embodiment, after configuring the target reply information of the target controlled device based on the target control condition and / or target control instruction, it includes: receiving a fourth control request instruction uploaded by the target controlled device; parsing the fourth control request instruction to determine whether the fourth control request instruction is a status query instruction; in case the fourth control request instruction is the status query instruction, sending third target reply information to the target controlled device, wherein the third target reply information is used to indicate the status of the target controlled device.
[0010] In an exemplary embodiment, the above-mentioned adjustment of the target control conditions and / or target control instructions corresponding to the above-mentioned target configuration options includes: selecting control conditions and / or control instructions from the existing configuration options; and using the selected control conditions and / or control instructions as the target control conditions and / or target control instructions corresponding to the above-mentioned target configuration options after adjustment.
[0011] In an exemplary embodiment, after the above-mentioned configuration page is displayed, it also includes: adding one or more processors to the above-mentioned configuration page; configuring parameters of the above-mentioned one or more processors, wherein the above-mentioned parameters include at least one of the processor name, the above-mentioned control conditions, the above-mentioned control instructions, the above-mentioned device information and the above-mentioned reply information.
[0012] In an exemplary embodiment, the above-mentioned adding one or more processors in the above-mentioned configuration page includes: when the calling mode of the processor is asynchronous callback, configuring a second processor in the above-mentioned configuration page, wherein the above-mentioned asynchronous callback means that when the first controlled device corresponding to the first processor completes the execution of the first control instruction, the second controlled device corresponding to the above-mentioned second processor executes the second control instruction; when the calling mode of the processor is non-asynchronous callback, configuring multiple third processors in the above-mentioned configuration page, wherein the above-mentioned non-asynchronous callback means that when the first controlled device corresponding to the first processor completes the execution of the first control instruction, the multiple third controlled devices corresponding to the above-mentioned multiple third processors execute multiple third control instructions, and the multiple third control instructions are different control instructions.
[0013] According to another embodiment of the embodiment of the present invention, there is also provided a device control apparatus, comprising: a display module, for displaying a configuration page, wherein a plurality of configuration options are displayed on the configuration page, each of the configuration options corresponds to at least one of a control condition, a control instruction, device information and a reply information, the control condition is used to trigger the corresponding control instruction, the control instruction is used to control the controlled device to perform a corresponding action, the device information is used to indicate the state of the controlled device, and the reply information is used for the controlled device to respond to a request instruction of a target user; an adjustment module, for adjusting a target control condition and / or a target control instruction corresponding to the target configuration option in response to a configuration adjustment request triggered by the target configuration option displayed on the configuration page; and a configuration module, for configuring the target reply information of the target controlled device based on the target control condition and / or the target control instruction.
[0014] According to another aspect of an embodiment of the present invention, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the above-mentioned device control method when running.
[0015] According to another aspect of an embodiment of the present invention, there is provided an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the device control method through the computer program.
[0016] In an embodiment of the present invention, a configuration page is displayed, wherein a plurality of configuration options are displayed on the configuration page, each configuration option corresponds to at least one of a control condition, a control instruction, device information, and a reply information, the control condition is used to trigger the corresponding control instruction, the control instruction is used to control the controlled device to perform the corresponding action, the device information is used to indicate the state of the controlled device, and the reply information is used for the controlled device to respond to the request instruction of the target user; in response to the configuration adjustment request triggered by the target configuration option displayed on the configuration page, the target control condition and / or target control instruction corresponding to the target configuration option is adjusted; based on the target control condition and / or target control instruction, the target reply information of the target controlled device is configured. By adopting the above technical solution, by adjusting the device function in the configuration page, it takes less time and is more efficient, and solves the technical problem of low efficiency due to the implementation of device function adjustment through code. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0018] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0019] Figure 1 is a schematic diagram of an application scenario of an optional device control method according to an embodiment of the present application;
[0020] Figure 2 is a flow chart of an optional device control method according to an embodiment of the present invention;
[0021] Figure 3 is a schematic diagram of an optional device control method according to an embodiment of the present invention;
[0022] Figure 4 is a structural block diagram of an optional device control apparatus according to an embodiment of the present invention. DETAILED DESCRIPTION
[0023] In order to enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of this application.
[0024] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0025] In an embodiment of the present invention, an embodiment of the above-mentioned device control method is provided. As an optional implementation, the device control method can be but is not limited to being applied to Figure 1 In the application environment shown.
[0026] Optionally, in this embodiment, after the user issues a voice command, such as "I want to take a shower", the configuration page performs semantic analysis on the voice command, configures the command according to the analysis result, and sends the configured command to the controlled device. After the controlled device receives the command, it completes the relevant operation. For example, if the controlled device is a water heater, after the water heater receives the command, it completes the operation of "turning on the water heater and setting the temperature to 42 degrees".
[0027] The above-mentioned controlled devices may not be limited to PCs, mobile phones, tablet computers, smart air conditioners, smart range hoods, smart refrigerators, smart ovens, smart stoves, smart washing machines, smart water heaters, smart washing equipment, smart dishwashers, smart projection equipment, smart TVs, smart clothes drying racks, smart curtains, smart audio and video, smart sockets, smart speakers, smart speakers, smart fresh air equipment, smart kitchen and bathroom equipment, smart bathroom equipment, smart sweeping robots, smart window cleaning robots, smart mopping robots, smart air purification equipment, smart steamers, smart microwave ovens, smart kitchen treasures, smart purifiers, smart water dispensers, smart door locks, etc.
[0028] In this embodiment, a device control method is provided. Figure 2 is a flow chart of a device control method according to an embodiment of the present invention, the flow chart includes the following steps:
[0029] Step S202, displaying a configuration page, wherein the configuration page displays a plurality of configuration options, each configuration option corresponds to at least one of a control condition, a control instruction, device information, and a reply information, wherein the control condition is used to trigger a corresponding control instruction, the control instruction is used to control the controlled device to perform a corresponding action, the device information is used to indicate the state of the controlled device, and the reply information is used for the controlled device to respond to the request instruction of the target user;
[0030] Step S204, in response to a configuration adjustment request triggered by a target configuration option displayed on the configuration page, adjusting a target control condition and / or a target control instruction corresponding to the target configuration option;
[0031] Step S206: configuring target reply information of the target controlled device based on the target control condition and / or the target control instruction.
[0032] Optionally, in this embodiment, the above configuration page may be, but is not limited to, a page for configuring and adjusting the control instructions of the controlled device. The configuration page may be, but is not limited to, parsing the voice instructions issued by the user using natural language processing, determining the control conditions according to the parsing results, and determining the corresponding control instructions based on the control conditions. For example, after the user issues a voice instruction "I want to take a bath", the control condition determined by the result of the natural language processing parsing is "I want to take a bath", and the control instruction corresponding to "I want to take a bath" is "turn on the water heater and set the temperature to 42 degrees", and the control instruction is sent to the water heater, thereby controlling the water heater to complete the relevant operations.
[0033] It should be noted that the user's demands for the controlled device may be different in different time periods. For example, when taking a bath in winter, the user hopes that the temperature of the water heater will be slightly higher, such as 42 degrees, while when taking a bath in summer, the user hopes that the temperature of the water heater will be slightly lower, such as 40 degrees; therefore, after receiving the configuration adjustment request, the control conditions and / or control instructions can be adjusted accordingly.
[0034] Optionally, in this embodiment, after the user issues a request instruction to the controlled device, if the controlled device cannot determine what type of action to perform based on the request instruction, the controlled device may, but is not limited to, send a reply message to the user to inform the user that the request instruction is unclear or further inquire the user to obtain a clear request instruction, etc.
[0035] Through the scheme provided by the embodiment of the present application, a configuration page is displayed, wherein a plurality of configuration options are displayed on the configuration page, each configuration option corresponds to at least one of a control condition, a control instruction, device information, and a reply information, the control condition is used to trigger the corresponding control instruction, the control instruction is used to control the controlled device to perform the corresponding action, the device information is used to indicate the state of the controlled device, and the reply information is used for the controlled device to respond to the request instruction of the target user; in response to the configuration adjustment request triggered by the target configuration option displayed on the configuration page, the target control condition and / or target control instruction corresponding to the target configuration option is adjusted; based on the target control condition and / or target control instruction, the target reply information of the target controlled device is configured. By adopting the above technical scheme, by adjusting the device function in the configuration page, it takes less time and is more efficient, and solves the technical problem of low efficiency due to the implementation of device function adjustment through code.
[0036] In an exemplary embodiment, after configuring the target reply information of the target controlled device based on the target control condition and / or the target control instruction, the method includes: receiving a first control request instruction and a second control request instruction uploaded by the target controlled device; parsing the first control request instruction to determine the first target control condition and / or the first target control instruction corresponding to the first control request instruction; parsing the second control request instruction to determine the second target control condition and / or the second target control instruction corresponding to the second control request instruction; and sending the first target reply information to the target controlled device when the first target control condition and the second target control condition are mutually exclusive or the first target control instruction and the second target control instruction are mutually exclusive, wherein the first target reply information is used to indicate that the target controlled device has failed to respond.
[0037] For example, the reply information of the request instruction when the controlled device executes two mutually exclusive instructions can be configured, such as "boot failed".
[0038] Through the solution provided by the embodiment of the present application, when the target controlled device receives two mutually exclusive request instructions, the first target reply information of the target controlled device is configured, thereby improving the user experience.
[0039] In an exemplary embodiment, after configuring the target reply information of the target controlled device based on the target control condition and / or the target control instruction, it includes: receiving a third control request instruction uploaded by the target controlled device; parsing the third control request instruction to determine whether the third control request instruction corresponds to a third target control condition and / or a third target control instruction; if the third control request instruction does not have a corresponding third target control condition and / or a third target control instruction, sending a second target reply information to the target controlled device, wherein the second target reply information is used to determine the third target control condition and / or the third target control instruction.
[0040] For example, you can configure a multi-round dialogue, and when the user asks to turn on the air conditioner, you can reply with "What is the temperature setting?"
[0041] Through the solution provided by the embodiment of the present application, when the target controlled device receives the third control request instruction, the second target reply information of the target processor is configured, thereby improving the user experience.
[0042] In an exemplary embodiment, after configuring the target reply information of the target controlled device based on the target control condition and / or the target control instruction, it includes: receiving a fourth control request instruction uploaded by the target controlled device; parsing the fourth control request instruction to determine whether the fourth control request instruction is a status query instruction; in the case that the fourth control request instruction is a status query instruction, sending third target reply information to the target controlled device, wherein the third target reply information is used to indicate the status of the target controlled device.
[0043] For example, you can configure the application type, attribute name, and reply message, such as: application type "air conditioning", attribute name: "fresh air on", reply message: "OK, the fresh air mode has been turned on for you."
[0044] Through the solution provided by the embodiment of the present application, when the target controlled device receives the fourth control request instruction, the third target reply information of the target processor is configured, thereby improving the user experience.
[0045] In an exemplary embodiment, adjusting the target control condition and / or target control instruction corresponding to the target configuration option includes: adjusting the target control condition to obtain the adjusted target control condition; after adjusting the target control condition and / or target control instruction corresponding to the target configuration option, including: in the case of obtaining a first control request matching the adjusted target control condition, obtaining the target control instruction, and controlling the controlled device to perform a first action through the target control instruction.
[0046] Optionally, in this embodiment, the control condition can be adjusted according to the actual needs of the user. For example, if the user is used to saying "I want to take a bath" but not "I want to take a shower", the control condition "I want to take a shower" can be adjusted to "I want to take a bath". After obtaining the "I want to take a bath" request from the user, the control instruction "turn on the water heater and set the temperature to 42 degrees" is sent to the water heater, thereby controlling the water heater to complete the relevant operations.
[0047] Through the solution provided in the embodiment of the present application, the flexibility of equipment control is improved by adjusting the control conditions.
[0048] In an exemplary embodiment, adjusting the target control condition and / or target control instruction corresponding to the target configuration option includes: adjusting the target control instruction to obtain an adjusted target control instruction; after adjusting the target control condition and / or target control instruction corresponding to the target configuration option, including: in the case of obtaining a second control request matching the target control condition, obtaining the adjusted target control instruction, and controlling the controlled device to perform a second action through the adjusted target control instruction.
[0049] Optionally, in this embodiment, the control instructions can be adjusted according to the actual needs of the user. For example, when the user takes a bath in winter, he or she may want the temperature of the water heater to be slightly higher, such as 42 degrees, and when taking a bath in summer, he or she may want the temperature of the water heater to be slightly lower, such as 40 degrees. Therefore, the control instructions can be adjusted accordingly in different time periods.
[0050] Through the solution provided in the embodiment of the present application, the flexibility of device control is improved by adjusting the control instructions.
[0051] In an exemplary embodiment, adjusting the target control conditions and / or target control instructions corresponding to the target configuration options includes: adjusting the target control conditions and the target control instructions to obtain adjusted target control conditions and the adjusted target control instructions; after adjusting the target control conditions and / or the target control instructions corresponding to the target configuration options, it includes: in the case of obtaining a third control request that matches the adjusted target control conditions, obtaining the adjusted target control instructions, and controlling the controlled device to perform a third action through the adjusted target control instructions.
[0052] Optionally, in this embodiment, the control conditions and control instructions can be adjusted simultaneously according to the actual needs of the user, and the adjustment of the control conditions and control instructions can include but is not limited to adding new control conditions and control instructions, modifying control conditions and control instructions, and deleting control conditions and control instructions.
[0053] Through the solution provided in the embodiment of the present application, the flexibility of device control is improved by adjusting the control conditions and control instructions.
[0054] In an exemplary embodiment, adjusting the target control condition and / or target control instruction corresponding to the target configuration option includes: selecting a control condition and / or control instruction from the existing configuration options; and using the selected control condition and / or control instruction as the target control condition and / or target control instruction corresponding to the adjusted target configuration option.
[0055] Optionally, in this embodiment, when adjusting the control condition and / or control instruction, the control condition and / or control instruction can be selected from the configuration options already in the database. For example, the database stores multiple optional configuration options, and the control condition and / or control instruction can be adjusted by selecting from a drop-down menu.
[0056] Through the solution provided in the embodiment of the present application, the control conditions and / or control instructions are adjusted by selecting from existing configuration options, thereby improving the efficiency of adjustment.
[0057] In an exemplary embodiment, after displaying the configuration page, it also includes: adding one or more processors to the configuration page; configuring parameters for one or more processors, wherein the parameters include at least one of the processor name, the above-mentioned control conditions, the above-mentioned control instructions, the above-mentioned device information, and the above-mentioned reply information.
[0058] Optionally, in this embodiment, the controlled device can be controlled by adding a processor in the configuration page and configuring parameters of the processor. The configuration parameters can be adjusted according to user needs, for example, added, deleted or adjusted.
[0059] Through the solution provided in the embodiment of the present application, the efficiency of adjusting the device functions is improved by configuring the processor in the configuration page.
[0060] In an exemplary embodiment, one or more processors are added to the configuration page, including: when the calling mode of the processor is asynchronous callback, a third processor is configured in the configuration page, wherein the asynchronous callback means that when the first controlled device corresponding to the first processor completes the execution of the first control instruction, the second controlled device corresponding to the second processor executes the second control instruction; when the calling mode of the processor is non-asynchronous callback, multiple third processors are configured in the configuration page, wherein the non-asynchronous callback means that when the first controlled device corresponding to the first processor completes the execution of the first control instruction, multiple third controlled devices corresponding to the multiple third processors execute multiple third control instructions, and the multiple third control instructions are different control instructions.
[0061] Optionally, in this embodiment, the working mode of the processor may include but is not limited to asynchronous callback and non-asynchronous callback; wherein, asynchronous callback means that after the current processor processes a response instruction, it triggers the next processor to respond to other instructions; non-asynchronous callback means that after the current processor processes a response instruction, it triggers multiple processors to respond to multiple different instructions at the same time. For example, in the asynchronous callback mode, after the user takes a bath, the next processor can be triggered to execute the response instruction of "I want to listen to music"; in the non-asynchronous callback mode, after the user takes a bath, multiple processors can be triggered to execute multiple different instructions such as "I want to listen to music" and "I want to use air conditioning" at the same time.
[0062] Through the solution provided in the embodiment of the present application, the flexibility of device control is improved by setting multiple working modes for the processor.
[0063] In order to better understand the process of the above-mentioned device control method, the above-mentioned device control method is described below in combination with an optional embodiment, but it is not used to limit the technical solution of the embodiment of the present invention.
[0064] In this embodiment, a schematic diagram of configuring parameters of a processor is provided, such as Figure 3 shown.
[0065] 1) Processor name
[0066] Enter a processor name. It must be unique and cannot be the same as an existing processor name.
[0067] 2) Control conditions
[0068] Add conditional options to the current processor. First select the condition type. The parameter values include NLP, device attributes, device status, device warning, home, environment, and execution result. If you select "Device Status", then configure the operation expression, such as "Equal", "Intent", and "37 degrees", which means that the intention of the device status being equal to 37 degrees is configured.
[0069] 3) Reply to message
[0070] Enter the content that the current processor expects the controlled device to respond to when the condition is triggered.
[0071] 4) Built-in processing
[0072] The built-in processor can select the device status and device list. When the device is processed using the processor, you can select whether the device to be processed is in the device list and the status of the device.
[0073] 5) Action
[0074] When setting an action, the processor can select different action types.
[0075] Device command: You can configure the application type, command name, and command value, such as the application type "water heater", the command name "power on / off status", and the command value "open".
[0076] Mutually exclusive reply: You can configure the reply message when the device executes two mutually exclusive commands, such as "boot failed".
[0077] Pre-query reply information: You can configure multiple rounds of dialogue. When the user asks to turn on the air conditioner, reply with "What is the temperature setting?"
[0078] Status query: You can configure the application type, attribute name, and reply information, such as: application type "air conditioning", attribute name: "Fresh air on", reply: "OK, the fresh air mode has been turned on for you."
[0079] Data management: You can configure the scene ID and node ID, and upload the cloud record log when the scene and node are triggered to collect data for analyzing the scene and node usage.
[0080] 6) Asynchronous callback
[0081] Asynchronous callback means that the current device can be configured with another processor with the same configuration parameters as the processor. When the device completes a certain action, it can trigger the configured command.
[0082] 7) Subprocessor
[0083] The sub-processor means that the current device can be configured with multiple processors. The configuration parameters of each processor are the same as the configuration of the processor. When the device completes a certain action, it can trigger the configured command.
[0084] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods of various embodiments of the present invention.
[0085] Figure 4 is a structural block diagram of a device control apparatus according to an embodiment of the present invention; Figure 4 As shown, including:
[0086] Display module 401, used to display a configuration page, wherein the configuration page displays multiple configuration options, each configuration option corresponds to at least one of a control condition, a control instruction, device information, and a reply message, the control condition is used to trigger the corresponding control instruction, the control instruction is used to control the controlled device to perform a corresponding action, the device information is used to indicate the state of the controlled device, and the reply message is used for the controlled device to respond to the request instruction of the target user;
[0087] An adjustment module 402, configured to adjust a target control condition and / or a target control instruction corresponding to a target configuration option displayed on a configuration page in response to a configuration adjustment request triggered by the target configuration option;
[0088] The configuration module 403 is used to configure the target response information of the target controlled device based on the target control condition and / or the target control instruction.
[0089] Through the scheme provided by the embodiment of the present application, a configuration page is displayed, wherein a plurality of configuration options are displayed on the configuration page, each configuration option corresponds to at least one of a control condition, a control instruction, device information, and a reply information, the control condition is used to trigger the corresponding control instruction, the control instruction is used to control the controlled device to perform the corresponding action, the device information is used to indicate the state of the controlled device, and the reply information is used for the controlled device to respond to the request instruction of the target user; in response to the configuration adjustment request triggered by the target configuration option displayed on the configuration page, the target control condition and / or target control instruction corresponding to the target configuration option is adjusted; based on the target control condition and / or target control instruction, the target reply information of the target controlled device is configured. By adopting the above technical scheme, by adjusting the device function in the configuration page, it takes less time and is more efficient, and solves the technical problem of low efficiency due to the implementation of device function adjustment through code.
[0090] An embodiment of the present invention further provides a storage medium, which includes a stored program, wherein the program executes any of the above methods when it is run.
[0091] Optionally, in this embodiment, the storage medium may be configured to store program codes for executing the following steps:
[0092] S1, displaying a configuration page, wherein the configuration page displays multiple configuration options, each configuration option corresponds to at least one of a control condition, a control instruction, device information, and a reply information, the control condition is used to trigger a corresponding control instruction, the control instruction is used to control the controlled device to perform a corresponding action, the device information is used to indicate the state of the controlled device, and the reply information is used for the controlled device to respond to the request instruction of the target user;
[0093] S2, in response to a configuration adjustment request triggered by a target configuration option displayed on the configuration page, adjusting a target control condition and / or a target control instruction corresponding to the target configuration option;
[0094] S3, configuring target response information of the target controlled device based on the target control condition and / or the target control instruction.
[0095] An embodiment of the present invention further provides an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.
[0096] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.
[0097] Optionally, in this embodiment, the processor may be configured to perform the following steps through a computer program:
[0098] S1, displaying a configuration page, wherein the configuration page displays multiple configuration options, each configuration option corresponds to at least one of a control condition, a control instruction, device information, and a reply information, the control condition is used to trigger a corresponding control instruction, the control instruction is used to control the controlled device to perform a corresponding action, the device information is used to indicate the state of the controlled device, and the reply information is used for the controlled device to respond to the request instruction of the target user;
[0099] S2, in response to a configuration adjustment request triggered by a target configuration option displayed on the configuration page, adjusting a target control condition and / or a target control instruction corresponding to the target configuration option;
[0100] S3, configuring target response information of the target controlled device based on the target control condition and / or the target control instruction.
[0101] Optionally, in this embodiment, the above-mentioned storage medium may include but is not limited to: a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk, and other media that can store program codes.
[0102] Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments and optional implementation modes, and this embodiment will not be described in detail here.
[0103] Obviously, those skilled in the art should understand that the above modules or steps of the present invention can be implemented by a general computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, and optionally, they can be implemented by a program code executable by a computing device, so that they can be stored in a storage device and executed by the computing device, and in some cases, the steps shown or described can be executed in a different order than here, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present invention is not limited to any specific combination of hardware and software.
[0104] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. A device control method, characterized in that: include: Displaying a configuration page, wherein the configuration page displays a plurality of configuration options, each of the configuration options corresponds to at least one of a control condition, a control instruction, device information, and a reply message, the control condition is used to trigger the corresponding control instruction, the control instruction is used to control the controlled device to perform a corresponding action, the device information is used to indicate the state of the controlled device, and the reply message is used for the controlled device to respond to the request instruction of the target user, so as to inform that the request instruction is unclear or to further inquire the user to obtain a clear request instruction; In response to a configuration adjustment request triggered by a target configuration option displayed on the configuration page, adjusting a target control condition and / or a target control instruction corresponding to the target configuration option; Based on the target control condition and / or the target control instruction, configure target reply information of the target controlled device; Receiving a first control request instruction and a second control request instruction uploaded by the target controlled device; parsing the first control request instruction to determine a first target control condition and / or a first target control instruction corresponding to the first control request instruction; parsing the second control request instruction to determine a second target control condition and / or a second target control instruction corresponding to the second control request instruction; In a case where the first target control condition and the second target control condition are mutually exclusive or the first target control instruction and the second target control instruction are mutually exclusive, sending first target reply information to the target controlled device, wherein the first target reply information is used to indicate that the target controlled device has failed to respond; Add one or more processors to the configuration page, wherein the working modes of the processors include asynchronous callback and non-asynchronous callback; In the case where the calling mode of the processor belongs to the asynchronous callback, a second processor is configured in the configuration page, wherein the asynchronous callback means that when the first controlled device corresponding to the first processor completes the execution of the first control instruction, the second controlled device corresponding to the second processor executes the second control instruction; In the case where the calling method of the processor belongs to the non-asynchronous callback, multiple third processors are configured in the configuration page, wherein the non-asynchronous callback indicates that when the first controlled device corresponding to the first processor completes the execution of the first control instruction, the multiple third controlled devices corresponding to the multiple third processors execute multiple third control instructions, and the multiple third control instructions are different control instructions.
2. The method according to claim 1, characterized in that After configuring the target reply information of the target controlled device based on the target control condition and / or the target control instruction, the method includes: Receiving a third control request instruction uploaded by the target controlled device; parsing the third control request instruction to determine whether the third control request instruction corresponds to a third target control condition and / or a third target control instruction; When the third control request instruction does not have the corresponding third target control condition and / or the third target control instruction, a second target reply message is sent to the target controlled device, wherein the second target reply message is used to determine the third target control condition and / or the third target control instruction.
3. The method according to claim 1, characterized in that After configuring the target reply information of the target controlled device based on the target control condition and / or the target control instruction, the method includes: Receiving a fourth control request instruction uploaded by the target controlled device; Parsing the fourth control request instruction to determine whether the fourth control request instruction is a status query instruction; In the case that the fourth control request instruction is the status query instruction, third target reply information is sent to the target controlled device, wherein the third target reply information is used to indicate the status of the target controlled device.
4. The method according to any one of claims 1 to 3, characterized in that: The adjusting the target control condition and / or target control instruction corresponding to the target configuration option includes: Select control conditions and / or control instructions from available configuration options; The selected control condition and / or control instruction is used as the target control condition and / or target control instruction corresponding to the adjusted target configuration option.
5. The method according to any one of claims 1 to 3, characterized in that: After the display configuration page, it also includes: Parameter configuration is performed on the one or more processors, wherein the parameters include at least one of a processor name, the control condition, the control instruction, the device information, and the reply information.
6. A device control device, characterized in that: include: A display module is used to display a configuration page, wherein the configuration page displays a plurality of configuration options, each of the configuration options corresponds to at least one of a control condition, a control instruction, device information, and a reply message, wherein the control condition is used to trigger the corresponding control instruction, the control instruction is used to control the controlled device to perform a corresponding action, the device information is used to indicate the state of the controlled device, and the reply message is used for the controlled device to respond to the request instruction of the target user, so as to inform that the request instruction is unclear or to further inquire the user to obtain a clear request instruction; an adjustment module, configured to adjust a target control condition and / or a target control instruction corresponding to a target configuration option displayed on the configuration page in response to a configuration adjustment request triggered by the target configuration option; A configuration module, configured to configure target reply information of a target controlled device based on the target control condition and / or the target control instruction; The device is also used for: After configuring the target reply information of the target controlled device based on the target control condition and / or the target control instruction, receiving the first control request instruction and the second control request instruction uploaded by the target controlled device; parsing the first control request instruction to determine a first target control condition and / or a first target control instruction corresponding to the first control request instruction; parsing the second control request instruction to determine a second target control condition and / or a second target control instruction corresponding to the second control request instruction; In a case where the first target control condition and the second target control condition are mutually exclusive or the first target control instruction and the second target control instruction are mutually exclusive, sending first target reply information to the target controlled device, wherein the first target reply information is used to indicate that the target controlled device has failed to respond; The device is also used for: After the configuration page, one or more processors are added to the configuration page, and the working modes of the processors include asynchronous callback and non-asynchronous callback; In the case where the calling mode of the processor belongs to the asynchronous callback, a second processor is configured in the configuration page, wherein the asynchronous callback means that when the first controlled device corresponding to the first processor completes the execution of the first control instruction, the second controlled device corresponding to the second processor executes the second control instruction; In the case where the calling mode of the processor belongs to the non-asynchronous callback, multiple third processors are configured in the configuration page, wherein the non-asynchronous callback indicates that when the first controlled device corresponding to the first processor completes the execution of the first control instruction, the multiple third controlled devices corresponding to the multiple third processors execute multiple third control instructions, and the multiple third control instructions are different control instructions.
7. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein the program executes the method according to any one of claims 1 to 5 when executed.
8. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to execute the method according to any one of claims 1 to 5 through the computer program.
Citation Information
Patent Citations
Instruction updating method, device, and electronic device
CN109213035A
Equipment control method and device, computer equipment and storage medium
CN113395193A
