CN117579409A - Control instruction processing method and device, storage medium and electronic device - Google Patents

Control instruction processing method and device, storage medium and electronic device Download PDF

Info

Publication number
CN117579409A
CN117579409A CN202311344410.3A CN202311344410A CN117579409A CN 117579409 A CN117579409 A CN 117579409A CN 202311344410 A CN202311344410 A CN 202311344410A CN 117579409 A CN117579409 A CN 117579409A
Authority
CN
China
Prior art keywords
equipment
standardized
attribute
control instruction
attribute value
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.)
Pending
Application number
CN202311344410.3A
Other languages
Chinese (zh)
Inventor
鲜文华
陈长运
张赛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Qingdao Haier Technology Co Ltd
Haier Smart Home Co Ltd
Haier Uplus Intelligent Technology Beijing Co Ltd
Original Assignee
Qingdao Haier Technology Co Ltd
Haier Smart Home Co Ltd
Haier Uplus Intelligent Technology Beijing Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Qingdao Haier Technology Co Ltd, Haier Smart Home Co Ltd, Haier Uplus Intelligent Technology Beijing Co Ltd filed Critical Qingdao Haier Technology Co Ltd
Priority to CN202311344410.3A priority Critical patent/CN117579409A/en
Publication of CN117579409A publication Critical patent/CN117579409A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/2803Home automation networks
    • H04L12/2816Controlling appliance services of a home automation network by calling their functionalities
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/2803Home automation networks
    • H04L12/283Processing of data at an internetworking point of a home automation network
    • H04L12/2834Switching of information between an external network and a home network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/02Standardisation; Integration
    • YGENERAL 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
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/02Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]

Abstract

The application discloses a control instruction processing method and device, a storage medium and an electronic device, and relates to the technical field of smart families, wherein the control instruction processing method comprises the following steps: under the condition that a control instruction sent by an interaction end is received, control information is analyzed from the control instruction, wherein the control information comprises an attribute name and/or an attribute value of first equipment to be controlled by the control instruction; the control information is standardized through a standardized rule; sending the standardized control information to a cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information; by adopting the scheme, the problem that the user experience is poor because different data influence the calculation flow when the user performs intelligent control due to different definitions of equipment attribute names and attribute values of different categories in the prior art is solved.

Description

Control instruction processing method and device, storage medium and electronic device
Technical Field
The application relates to the technical field of smart families, in particular to a control instruction processing method and device, a storage medium and an electronic device.
Background
Aiming at the Internet of things equipment with different communication technologies, seamless interaction between the equipment can be realized at present. The end user does not have to worry about the mutual co-operation of the devices. These devices are developed in various hardware industries, and have differences in device protocols, device report states, device issue instructions, device cooperative dependencies, and the like.
In the prior art, if the difference is solved, a developer needs to hard code at the front end, the development workload is large, the development period is long, and the multi-section development is not uniform logic; if this variability is not handled, the data of the variability will affect the computational flow and is often not clear enough.
Aiming at the problems of poor user experience and the like caused by different data influencing the calculation flow when a user performs intelligent control because the definitions of the attribute names and the attribute values of the equipment of different categories are different in the related technology, an effective solution is not proposed yet.
Disclosure of Invention
The embodiment of the invention provides a processing method and device of a control instruction, a storage medium and an electronic device, which are used for at least solving the problems that different types of equipment attribute names and attribute values are defined differently, and when a user performs intelligent control, the differential data influence a calculation flow, so that the user experience is poor.
According to an embodiment of the present invention, there is provided a method for processing a control instruction, including: under the condition that a control instruction sent by an interaction end is received, control information is analyzed from the control instruction, wherein the control information comprises an attribute name and/or an attribute value of first equipment to be controlled by the control instruction; the control information is standardized through a standardized rule; and sending the standardized control information to a cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information.
In an exemplary embodiment, after sending the standardized control information to the cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information, the method further includes: receiving response information sent by the cloud platform, wherein the response information is used for controlling the first equipment; matching a target mapping relation in a preset rule file according to a first equipment subcategory of the first equipment, wherein the preset rule is used for storing the standardized rule, and the target mapping relation is used for indicating the mapping relation between the attribute name and a standard attribute name and the mapping relation between the attribute value and a standard attribute value in a standard attribute value domain; and converting the response information according to the target mapping relation, and sending the converted response information to the first equipment.
In an exemplary embodiment, before normalizing the control information by the normalization rule, the method further comprises: determining that a preset rule file is to be generated by the second equipment under the condition that the second equipment of the same equipment category in the target family comprises a plurality of third equipment of a plurality of equipment subcategories and attribute names and/or attribute values among the plurality of third equipment are different, wherein the preset rule file is used for storing the standardized rule; acquiring attribute names and attribute value fields of each third device, wherein the attribute value fields are used for indicating all attribute values of the third devices, and the attribute names are in one-to-one correspondence with the attribute value fields; and generating the preset rule file of the second device according to the attribute name and the attribute value field of each third device.
In an exemplary embodiment, generating the preset rule file of the second device according to the attribute name and the attribute value field of each third device includes: determining an attribute name of a target third device of the plurality of third devices as a standard attribute name of the second device, and determining an attribute value range of the target third device as a standard attribute value range of the second device; or determining the standard attribute name and the standard attribute value field according to a configuration operation of the first object, wherein the configuration operation is used for configuring the standard attribute name and the standard attribute value field.
In an exemplary embodiment, the method further comprises: the preset rule file includes: standard attribute name, standard attribute value field, equipment matching information; wherein the device matching information includes: the mapping relation between the attribute value fields of each third device and the standard attribute value fields is standardized; wherein the standardized set of devices comprises: constraining the device subcategories and configuring the device subcategories; the constraint device subcategory is used for indicating a plurality of device subcategories of the plurality of third devices, and the configuration device subcategory is used for indicating the device subcategory of a target third device which has no authority to access the preset rule file in the plurality of third devices.
In an exemplary embodiment, normalizing the control information by a normalization rule includes: matching a first device subcategory of the first device in the standardized set of devices; and under the condition that the constraint equipment sub-category comprises the first equipment sub-category and the configuration equipment sub-category does not comprise the first equipment sub-category, normalizing the attribute name according to the standard attribute name and normalizing the attribute value according to the mapping relation.
In an exemplary embodiment, after sending the standardized control information to the cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information, the method further includes: and under the condition that the third device of the second device sub-category is newly added in the target family, updating the preset rule file according to the third device of the second device sub-category, wherein the plurality of device sub-categories do not comprise the second device sub-category.
According to another embodiment of the present invention, there is also provided a processing apparatus for a control instruction, including: the analysis module is used for analyzing control information from the control instruction under the condition that the control instruction sent by the interaction end is received, wherein the control information comprises an attribute name and/or an attribute value of first equipment to be controlled by the control instruction; the normalization module is used for normalizing the control information through a normalization rule; and the sending module is used for sending the standardized control information to the cloud platform so as to instruct the cloud platform to respond to the control instruction according to the standardized control information.
According to still another aspect of the embodiments of the present invention, there is also provided a computer-readable storage medium having a computer program stored therein, wherein the computer program is configured to execute the processing method of the control instruction described above when executed.
According to still another aspect of the embodiments of the present invention, there is further provided an electronic device including a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein the processor executes the processing method of the control instruction by the computer program.
In the embodiment of the application, if a control instruction sent by an interaction end is received, firstly analyzing an attribute name and/or an attribute value of a first device from the control instruction, wherein the first device is a device to be controlled by the control instruction; then, the control information is standardized through a standardized rule, the standardized control information is sent to the cloud platform, and the cloud platform is instructed to respond to the control instruction according to the standardized control information; by adopting the scheme, the problem that the user experience is poor because different data influence the calculation flow when the user performs intelligent control due to different definitions of equipment attribute names and attribute values of different categories in the prior art is solved; and (3) standardizing the control instruction between the interaction end and the cloud platform by configuring a preset rule file, and unifying different attribute definitions.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description, serve to explain the principles of the application.
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings that are required to be used in the description of the embodiments or the prior art will be briefly described below, and it will be obvious to those skilled in the art that other drawings can be obtained from these drawings without inventive effort.
FIG. 1 is a schematic diagram of a hardware environment of an alternative control instruction processing method according to an embodiment of the present application;
FIG. 2 is a flow chart of an alternative control instruction processing method according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of an alternative preset rule file according to an embodiment of the present invention;
FIG. 4 is a schematic illustration of an alternative application scenario in accordance with an embodiment of the present invention;
FIG. 5 is a flow chart of an alternative control instruction processing method according to an embodiment of the present invention;
FIG. 6 is a block diagram of an alternative control instruction processing apparatus according to an embodiment of the present invention.
Detailed Description
In order to make the present application solution better understood by those skilled in the art, the following description will be made in detail and with reference to the accompanying drawings in the embodiments of the present application, it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by one of ordinary skill in the art based on the embodiments herein without making any inventive effort, shall fall within the scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that embodiments of the present application described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
According to one aspect of the embodiments of the present application, a method for processing a control instruction is provided. The processing method of the control instruction is widely applied to full-house intelligent digital control application scenes such as intelligent Home (Smart Home), intelligent Home equipment ecology, intelligent Home (Intelligence House) ecology and the like. Alternatively, in the present embodiment, the processing method of the control instruction described above may be applied to a hardware environment constituted by the terminal device 102 and the server 104 as shown in fig. 1. As shown in fig. 1, the server 104 is connected to the terminal device 102 through a network, and may be used to provide services (such as application services and the like) for a terminal or a client installed on the terminal, a database may be set on the server or independent of the server, for providing data storage services for the server 104, and cloud computing and/or edge computing services may be configured on the server or independent of the server, for providing data computing services for the server 104.
The network may include, but is not limited to, at least one of: wired network, wireless network. The wired network may include, but is not limited to, at least one of: a wide area network, a metropolitan area network, a local area network, and the wireless network may include, but is not limited to, at least one of: WIFI (Wireless Fidelity ), bluetooth. The terminal device 102 may not be limited to a PC, a mobile phone, a tablet computer, an intelligent air conditioner, an intelligent smoke machine, a refrigerator device, an intelligent oven, an intelligent cooking range, an intelligent washing machine, an intelligent water heater, an intelligent washing device, an intelligent dish washer, an intelligent projection device, an intelligent television, an intelligent clothes hanger, an intelligent curtain, an intelligent video, an intelligent socket, an intelligent sound box, an intelligent fresh air device, an intelligent kitchen and toilet device, an intelligent bathroom device, an intelligent sweeping robot, an intelligent window cleaning robot, an intelligent mopping robot, an intelligent air purifying device, an intelligent steam box, an intelligent microwave oven, an intelligent kitchen appliance, an intelligent purifier, an intelligent water dispenser, an intelligent door lock, and the like.
In this embodiment, a method for processing a control instruction is provided, which is applied to a computer terminal or a standardized service layer, and fig. 2 is a flowchart of an alternative method for processing a control instruction according to an embodiment of the present invention, where the flowchart includes the following steps:
step S202, under the condition that a control instruction sent by an interaction end is received, control information is analyzed from the control instruction, wherein the control information comprises an attribute name and/or an attribute value of first equipment to be controlled by the control instruction;
step S204, the control information is standardized through a standardized rule;
step S206, the standardized control information is sent to a cloud platform, so that the cloud platform is instructed to respond to the control instruction according to the standardized control information.
In the embodiment of the application, if a control instruction sent by an interaction end is received, firstly analyzing an attribute name and/or an attribute value of a first device from the control instruction, wherein the first device is a device to be controlled by the control instruction; then, the control information is standardized through a standardized rule, the standardized control information is sent to the cloud platform, and the cloud platform is instructed to respond to the control instruction according to the standardized control information; by adopting the scheme, the problem that the user experience is poor because different data influence the calculation flow when the user performs intelligent control due to different definitions of equipment attribute names and attribute values of different categories in the prior art is solved; and (3) standardizing the control instruction between the interaction end and the cloud platform by configuring a preset rule file, and unifying different attribute definitions.
Optionally, the above step S206 is performed: after sending the standardized control information to a cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information, the method further comprises: receiving response information sent by the cloud platform, wherein the response information is used for controlling the first equipment; matching a target mapping relation in a preset rule file according to a first equipment subcategory of the first equipment, wherein the preset rule file is used for storing the standardized rule, and the target mapping relation is used for indicating the mapping relation between the attribute name and a standard attribute name and the mapping relation between the attribute value and a standard attribute value in a standard attribute value domain; and converting the response information according to the target mapping relation, and sending the converted response information to the first equipment.
After the control information is standardized and sent to the cloud platform, the cloud platform responds to the control information and receives response information sent by the cloud platform, wherein the response information is used for controlling the first equipment according to the control instruction; but the response information is generated based on the cloud platform, namely, the attribute name and the attribute value are corresponding to the cloud platform, and the first equipment cannot be directly analyzed, so that the first equipment needs to be converted, a target mapping relation is matched in a preset rule file according to a first equipment subcategory of the first equipment, the preset rule file is used for storing the standardized rule, and the target mapping relation is used for indicating the mapping relation between the attribute name and the standard attribute name and the mapping relation between the attribute value and the standard attribute value in a standard attribute value domain; and then converting the response information according to the target mapping relation, and then transmitting the converted response information to the first equipment to control the first equipment.
Optionally, the above step S204 is performed: before normalizing the control information by the normalization rule, the method further comprises: determining that a preset rule file is to be generated by the second equipment under the condition that the second equipment of the same equipment category in the target family comprises a plurality of third equipment of a plurality of equipment subcategories and attribute names and/or attribute values among the plurality of third equipment are different, wherein the preset rule file is used for storing the standardized rule; acquiring attribute names and attribute value fields of each third device, wherein the attribute value fields are used for indicating all attribute values of the third devices, and the attribute names are in one-to-one correspondence with the attribute value fields; and generating the preset rule file of the second device according to the attribute name and the attribute value field of each third device.
Before the control information is standardized and the response information is converted by adopting the scheme, a preset rule file of the second device is required to be generated, and the process of generating the preset rule file comprises the following steps: when it is determined that a second device of the same device class in a target family where a user is located contains a plurality of third devices of a plurality of device subcategories and attribute names and/or attribute values among the plurality of third devices are different, determining that the second device needs to generate a preset rule file to be standardized, and firstly acquiring the attribute name and the attribute value field of each third device, wherein the attribute value field contains all values of the attribute values, and the attribute names and the attribute value fields are in one-to-one correspondence, namely, each attribute name corresponds to one attribute value field; and then generating a preset rule file of each third device according to the attribute name and the attribute value field of the second device.
Optionally, the generating step includes: the generating a preset rule file of the second device according to the attribute name and the attribute value field of each third device may specifically include: determining an attribute name of a target third device of the plurality of third devices as a standard attribute name of the second device, and determining an attribute value range of the target third device as a standard attribute value range of the second device; or determining the standard attribute name and the standard attribute value field according to a configuration operation of the first object, wherein the configuration operation is used for configuring the standard attribute name and the standard attribute value field.
The process of generating the preset rule file specifically includes: after obtaining the attribute name and the attribute value field of each third device, if the cloud platform has the attribute name and the attribute value field corresponding to the standard device stored therein, determining the attribute name of the corresponding target third device as the standard attribute name, and determining the attribute value field of the target third device as the standard attribute value field; if the cloud platform is not stored, a certain third device can be determined to be a target third device according to the selection of a user.
Optionally, the method further comprises: the preset rule file includes: standard attribute name, standard attribute value field, equipment matching information; wherein the device matching information includes: the mapping relation between the attribute value fields of each third device and the standard attribute value fields is standardized; wherein the standardized set of devices comprises: constraining the device subcategories and configuring the device subcategories; the constraint device subcategory is used for indicating a plurality of device subcategories of the plurality of third devices, and the configuration device subcategory is used for indicating the device subcategory of a target third device which has no authority to access the preset rule file in the plurality of third devices.
The preset rule file includes at least the following fields: the device matching information comprises a standard attribute name, a standard attribute value field and device matching information, wherein the device matching information comprises: the mapping relation between the attribute value fields of each third device and the standard attribute value fields is standardized; the standardized set of devices includes: constraint device subcategories and configuration device subcategories; the constraint device subcategory is used for indicating a plurality of device subcategories of the plurality of third devices, and the configuration device subcategory is used for indicating the device subcategory of the target third device of which the plurality of third devices have no authority to access the preset rule file.
It should be noted that, the preset rule file may further include other fields, as shown in fig. 3, fig. 3 is a schematic structural diagram of an optional preset rule file according to an embodiment of the present invention, which specifically includes:
name (standardized attribute Name): standardized target attribute Key;
desc: describing attributes;
ValueType: standardizing the value type of the target attribute;
ValueRange (standard attribute value range): normalizing the value range of the target attribute;
mappers (device matching information): the equipment set matcher for standardized products comprises a devices, name, values three-layer structure.
Mappers specifically include:
deivcs: a standardized set of equipment comprising excludes, includes two layers:
excludes (configure device subcategories): excluding equipment range;
includes (constraint device subcategories): restricting the device range.
Name: original attribute Key;
values: the mapping relationship between the original attribute value and the target attribute value comprises a originalValue, standardValue two-layer structure:
OriginalValue: original attribute values;
standard value: target value.
Optionally, step S204 is as follows: normalizing the control information by a normalization rule, comprising: matching a first device subcategory of the first device in the standardized set of devices; and under the condition that the constraint equipment sub-category comprises the first equipment sub-category and the configuration equipment sub-category does not comprise the first equipment sub-category, normalizing the attribute name according to the standard attribute name and normalizing the attribute value according to the mapping relation.
The process of normalizing the control information includes: firstly, a first equipment sub-category of the first equipment is matched in a standardized equipment set, if the constraint equipment sub-category comprises the first equipment sub-category and the configuration equipment sub-category does not comprise the first equipment sub-category, the control information is allowed to be standardized by adopting the preset rule file, an attribute name is standardized into the standard attribute name, and then the attribute value is standardized according to the mapping relation; if the constraint device subcategory does not include the first device subcategory and/or the configuration device subcategory includes the first device subcategory, the control information is not allowed to be standardized using the preset rule file.
Optionally, the above step S206 is performed: after sending the standardized control information to a cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information, the method further comprises: and under the condition that the third device of the second device sub-category is newly added in the target family, updating the preset rule file according to the third device of the second device sub-category, wherein the plurality of device sub-categories do not comprise the second device sub-category.
If it is determined that the third device of the second device sub-category is newly added in the target home where the user is located, updating the preset rule file according to the third device of the second device sub-category, where the plurality of device sub-categories do not include the second device sub-category. The updating process is to update constraint equipment subcategories and configuration equipment subcategories in the equipment matching information; updating a mapping relationship between the attribute value field of the third device of the second device subcategory and the standardized attribute value field, and the like.
An application scenario of the present invention is shown in fig. 4, and fig. 4 is a schematic diagram of an alternative application scenario in an embodiment of the present invention: the data received by the cloud platform server of the Internet of things comprises the on-off states reported by different devices, and the on-off states comprise: allOnOffStatus, onOffStatus, curtainStatus information (specific attribute information, including value fields, descriptions, etc. of attribute reports). The definition of a certain attribute (i.e. attribute name, etc.) is different for different classes of devices, but the services provided are the same.
With more and more types of equipment access, the interactive terminal side is more and more diversified (APP, multi-screen, applet and Web detail page), so that compatible adaptation work for the same service is greatly increased, the maintenance cost is higher, and the flexibility is poor.
For the above application scenario, the present invention provides a solution, as shown in fig. 5, and fig. 5 is a schematic flow chart of an alternative control instruction processing method according to an embodiment of the present invention.
By constructing a middle layer, namely a standardized service layer, between the interaction side and the gateway and carrying out standardized processing on data through a rule file (preset rule file), equipment difference is eliminated, so that the interaction side does not need to call service logic by hard coding, and one set of codes can be compatible with the operation capability of multiple types of equipment.
As shown in fig. 5, the interactive side gateway reports respective attribute values, including: allnOffStatus: "true", onOffStatus: "1", curtannstatus: "1" …; the attributes are used for indicating the switch, but the attribute names are different, and the corresponding specific attribute values are not completely the same; the rule files passing through the standardized service layer are converted, and the attribute values are unified into OnOffStatus: "true"; after the operation device is uploaded to the gateway, the gateway can identify that the operation device is turned on or off; and then, when the gateway issues the equipment operation instruction, the equipment operation instruction is converted by the standardized service layer and analyzed into equipment attribute source data, and the equipment instruction data is issued through the Internet of things cloud platform to complete equipment control.
From the description of the above embodiments, it will be clear to a person skilled in the art that the method according to the above embodiments may be implemented by means of software plus the necessary general hardware platform, but of course also by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (e.g. ROM/RAM, magnetic disk, optical disk) comprising several instructions for causing a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to perform the method of the various embodiments of the present invention.
In this embodiment, a processing device for a control instruction is further provided, and the processing device for a control instruction is used to implement the foregoing embodiments and preferred embodiments, which have already been described and will not be described in detail. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. While the means described in the following embodiments are preferably implemented in software, implementation in hardware, or a combination of software and hardware, is also possible and contemplated.
FIG. 6 is a block diagram of an alternative control instruction processing apparatus according to an embodiment of the present invention; as shown in fig. 6, includes:
the parsing module 62 is configured to parse control information from a control instruction sent by an interaction end when the control instruction is received, where the control information includes an attribute name and/or an attribute value of a first device to be controlled by the control instruction;
a normalization module 64 for normalizing the control information by a normalization rule;
and the sending module 66 is configured to send the standardized control information to a cloud platform, so as to instruct the cloud platform to respond to the control instruction according to the standardized control information.
Through the device, if the control instruction sent by the interaction end is received, the attribute name and/or the attribute value of the first equipment are/is analyzed from the control instruction, and the first equipment is the equipment to be controlled by the control instruction; then, the control information is standardized through a standardized rule, the standardized control information is sent to the cloud platform, and the cloud platform is instructed to respond to the control instruction according to the standardized control information; by adopting the scheme, the problem that the user experience is poor because different data influence the calculation flow when the user performs intelligent control due to different definitions of equipment attribute names and attribute values of different categories in the prior art is solved; and (3) standardizing the control instruction between the interaction end and the cloud platform by configuring a preset rule file, and unifying different attribute definitions.
Optionally, the sending module 66 is further configured to receive response information sent by the cloud platform, where the response information is used to control the first device; matching a target mapping relation in a preset rule file according to a first equipment subcategory of the first equipment, wherein the preset rule file is used for storing the standardized rule, and the target mapping relation is used for indicating the mapping relation between the attribute name and a standard attribute name and the mapping relation between the attribute value and a standard attribute value in a standard attribute value domain; and converting the response information according to the target mapping relation, and sending the converted response information to the first equipment.
After the control information is standardized and sent to the cloud platform, the cloud platform responds to the control information and receives response information sent by the cloud platform, wherein the response information is used for controlling the first equipment according to the control instruction; but the response information is generated based on the cloud platform, namely, the attribute name and the attribute value are corresponding to the cloud platform, and the first equipment cannot be directly analyzed, so that the first equipment needs to be converted, a target mapping relation is matched in a preset rule file according to a first equipment subcategory of the first equipment, the preset rule file is used for storing the standardized rule, and the target mapping relation is used for indicating the mapping relation between the attribute name and the standard attribute name and the mapping relation between the attribute value and the standard attribute value in a standard attribute value domain; and then converting the response information according to the target mapping relation, and then transmitting the converted response information to the first equipment to control the first equipment.
Optionally, the normalization module 64 is further configured to determine that the second device is to generate a preset rule file when it is determined that the second device in the same device class in the target home includes a plurality of third devices in a plurality of device subcategories, and attribute names and/or attribute values between the plurality of third devices are different, where the preset rule file is used to store the normalization rule; acquiring attribute names and attribute value fields of each third device, wherein the attribute value fields are used for indicating all attribute values of the third devices, and the attribute names are in one-to-one correspondence with the attribute value fields; and generating the preset rule file of the second device according to the attribute name and the attribute value field of each third device.
Before the control information is standardized and the response information is converted by adopting the scheme, a preset rule file of the second device is required to be generated, and the process of generating the preset rule file comprises the following steps: when it is determined that a second device of the same device class in a target family where a user is located contains a plurality of third devices of a plurality of device subcategories and attribute names and/or attribute values among the plurality of third devices are different, determining that the second device needs to generate a preset rule file to be standardized, and firstly acquiring the attribute name and the attribute value field of each third device, wherein the attribute value field contains all values of the attribute values, and the attribute names and the attribute value fields are in one-to-one correspondence, namely, each attribute name corresponds to one attribute value field; and then generating a preset rule file of each third device according to the attribute name and the attribute value field of the second device.
Optionally, the normalizing module 64 is further configured to determine an attribute name of a target third device of the plurality of third devices as a standard attribute name of the second device, and determine an attribute value range of the target third device as a standard attribute value range of the second device; or determining the standard attribute name and the standard attribute value field according to a configuration operation of the first object, wherein the configuration operation is used for configuring the standard attribute name and the standard attribute value field.
The process of generating the preset rule file specifically includes: after obtaining the attribute name and the attribute value field of each third device, if the cloud platform has the attribute name and the attribute value field corresponding to the standard device stored therein, determining the attribute name of the corresponding target third device as the standard attribute name, and determining the attribute value field of the target third device as the standard attribute value field; if the cloud platform is not stored, a certain third device can be determined to be a target third device according to the selection of a user.
Optionally, the normalization module 64 is further configured to generate the preset rule file, where the preset rule file includes: standard attribute name, standard attribute value field, equipment matching information; wherein the device matching information includes: the mapping relation between the attribute value fields of each third device and the standard attribute value fields is standardized; wherein the standardized set of devices comprises: constraining the device subcategories and configuring the device subcategories; the constraint device subcategory is used for indicating a plurality of device subcategories of the plurality of third devices, and the configuration device subcategory is used for indicating the device subcategory of a target third device which has no authority to access the preset rule file in the plurality of third devices.
The preset rule file includes at least the following fields: the device matching information comprises a standard attribute name, a standard attribute value field and device matching information, wherein the device matching information comprises: the mapping relation between the attribute value fields of each third device and the standard attribute value fields is standardized; the standardized set of devices includes: constraint device subcategories and configuration device subcategories; the constraint device subcategory is used for indicating a plurality of device subcategories of the plurality of third devices, and the configuration device subcategory is used for indicating the device subcategory of the target third device of which the plurality of third devices have no authority to access the preset rule file.
Optionally, the normalization module 64 is further configured to match a first device subcategory of the first device in the standardized device set; and under the condition that the constraint equipment sub-category comprises the first equipment sub-category and the configuration equipment sub-category does not comprise the first equipment sub-category, normalizing the attribute name according to the standard attribute name and normalizing the attribute value according to the mapping relation.
The process of normalizing the control information includes: firstly, a first equipment sub-category of the first equipment is matched in a standardized equipment set, if the constraint equipment sub-category comprises the first equipment sub-category and the configuration equipment sub-category does not comprise the first equipment sub-category, the control information is allowed to be standardized by adopting the preset rule file, an attribute name is standardized into the standard attribute name, and then the attribute value is standardized according to the mapping relation; if the constraint device subcategory does not include the first device subcategory and/or the configuration device subcategory includes the first device subcategory, the control information is not allowed to be standardized using the preset rule file.
Optionally, the sending module 66 is further configured to update the preset rule file according to the third device of the second device sub-class if it is determined that the third device of the second device sub-class is newly added in the target home, where the plurality of device sub-classes does not include the second device sub-class.
If it is determined that the third device of the second device sub-category is newly added in the target home where the user is located, updating the preset rule file according to the third device of the second device sub-category, where the plurality of device sub-categories do not include the second device sub-category. The updating process is to update constraint equipment subcategories and configuration equipment subcategories in the equipment matching information; updating a mapping relationship between the attribute value field of the third device of the second device subcategory and the standardized attribute value field, and the like.
An embodiment of the present invention also provides a storage medium including a stored program, wherein the program executes the method of any one of the above.
Alternatively, in the present embodiment, the above-described storage medium may be configured to store program code for performing the steps of:
s1, under the condition that a control instruction sent by an interaction end is received, analyzing control information from the control instruction, wherein the control information comprises an attribute name and/or an attribute value of first equipment to be controlled by the control instruction;
S2, standardizing the control information through a standardization rule;
and S3, sending the standardized control information to a cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information.
An embodiment of the invention also provides an electronic device comprising a memory having stored therein a computer program and a processor arranged to run the computer program to perform the steps of any of the method embodiments described above.
Optionally, the electronic apparatus may further include a transmission device and an input/output device, where the transmission device is connected to the processor, and the input/output device is connected to the processor.
Alternatively, in the present embodiment, the above-described processor may be configured to execute the following steps by a computer program:
s1, under the condition that a control instruction sent by an interaction end is received, analyzing control information from the control instruction, wherein the control information comprises an attribute name and/or an attribute value of first equipment to be controlled by the control instruction;
s2, standardizing the control information through a standardization rule;
And S3, sending the standardized control information to a cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information.
Alternatively, in the present embodiment, the storage medium may include, but is not limited to: a U-disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a removable hard disk, a magnetic disk, or an optical disk, or other various media capable of storing program codes.
Alternatively, specific examples in this embodiment may refer to examples described in the foregoing embodiments and optional implementations, and this embodiment is not described herein.
It will be appreciated by those skilled in the art that the modules or steps of the invention described above may be implemented in a general purpose computing device, they may be concentrated on a single computing device, or distributed across a network of computing devices, they may alternatively be implemented in program code executable by computing devices, so that they may be stored in a memory device for execution by computing devices, and in some cases, the steps shown or described may be performed in a different order than that shown or described, or they may be separately fabricated into individual integrated circuit modules, or multiple modules or steps within them may be fabricated into a single integrated circuit module for implementation. Thus, the present invention is not limited to any specific combination of hardware and software.
The above description is only of the preferred embodiments of the present invention and is not intended to limit the present invention, but various modifications and variations can be made to the present invention by those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the principle of the present invention should be included in the protection scope of the present invention.

Claims (10)

1. A method of processing a control instruction, comprising:
under the condition that a control instruction sent by an interaction end is received, control information is analyzed from the control instruction, wherein the control information comprises an attribute name and/or an attribute value of first equipment to be controlled by the control instruction;
the control information is standardized through a standardized rule;
and sending the standardized control information to a cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information.
2. The method according to claim 1, wherein after sending standardized control information to a cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information, the method further comprises:
Receiving response information sent by the cloud platform, wherein the response information is used for controlling the first equipment;
matching a target mapping relation in a preset rule file according to a first equipment subcategory of the first equipment, wherein the preset rule file is used for storing the standardized rule, and the target mapping relation is used for indicating the mapping relation between the attribute name and a standard attribute name and the mapping relation between the attribute value and a standard attribute value in a standard attribute value domain;
and converting the response information according to the target mapping relation, and sending the converted response information to the first equipment.
3. The method according to claim 1, characterized in that before normalizing the control information by a normalization rule, the method further comprises:
determining that a preset rule file is to be generated by the second equipment under the condition that the second equipment of the same equipment category in the target family comprises a plurality of third equipment of a plurality of equipment subcategories and attribute names and/or attribute values among the plurality of third equipment are different, wherein the preset rule file is used for storing the standardized rule;
Acquiring attribute names and attribute value fields of each third device, wherein the attribute value fields are used for indicating all attribute values of the third devices, and the attribute names are in one-to-one correspondence with the attribute value fields;
and generating the preset rule file of the second device according to the attribute name and the attribute value field of each third device.
4. A method of processing a control instruction according to claim 3, wherein generating the preset rule file of the second device from the attribute name and the attribute value field of the each third device comprises:
determining an attribute name of a target third device of the plurality of third devices as a standard attribute name of the second device, and determining an attribute value range of the target third device as a standard attribute value range of the second device; or (b)
And determining the standard attribute name and the standard attribute value field according to the configuration operation of the first object, wherein the configuration operation is used for configuring the standard attribute name and the standard attribute value field.
5. A method of processing a control instruction according to claim 3, further comprising: the preset rule file includes: standard attribute name, standard attribute value field, equipment matching information; wherein the device matching information includes: the mapping relation between the attribute value fields of each third device and the standard attribute value fields is standardized; wherein the standardized set of devices comprises: constraining the device subcategories and configuring the device subcategories; the constraint device subcategory is used for indicating a plurality of device subcategories of the plurality of third devices, and the configuration device subcategory is used for indicating the device subcategory of a target third device which has no authority to access the preset rule file in the plurality of third devices.
6. The method according to claim 5, wherein normalizing the control information by a normalization rule, comprises:
matching a first device subcategory of the first device in the standardized set of devices;
and under the condition that the constraint equipment sub-category comprises the first equipment sub-category and the configuration equipment sub-category does not comprise the first equipment sub-category, normalizing the attribute name according to the standard attribute name and normalizing the attribute value according to the mapping relation.
7. The method according to claim 3, wherein after sending standardized control information to a cloud platform to instruct the cloud platform to respond to the control instruction according to the standardized control information, the method further comprises:
and under the condition that the third device of the second device sub-category is newly added in the target family, updating the preset rule file according to the third device of the second device sub-category, wherein the plurality of device sub-categories do not comprise the second device sub-category.
8. A control instruction processing apparatus, comprising:
The analysis module is used for analyzing control information from the control instruction under the condition that the control instruction sent by the interaction end is received, wherein the control information comprises an attribute name and/or an attribute value of first equipment to be controlled by the control instruction;
the normalization module is used for normalizing the control information through a normalization rule;
and the sending module is used for sending the standardized control information to the cloud platform so as to instruct the cloud platform to respond to the control instruction according to the standardized control information.
9. A computer-readable storage medium, characterized in that the computer-readable storage medium comprises a stored program, wherein the program, when run, performs the method of any one of claims 1 to 7.
10. An electronic device comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to execute the method according to any of the claims 1 to 7 by means of the computer program.
CN202311344410.3A 2023-10-17 2023-10-17 Control instruction processing method and device, storage medium and electronic device Pending CN117579409A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311344410.3A CN117579409A (en) 2023-10-17 2023-10-17 Control instruction processing method and device, storage medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311344410.3A CN117579409A (en) 2023-10-17 2023-10-17 Control instruction processing method and device, storage medium and electronic device

Publications (1)

Publication Number Publication Date
CN117579409A true CN117579409A (en) 2024-02-20

Family

ID=89885157

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311344410.3A Pending CN117579409A (en) 2023-10-17 2023-10-17 Control instruction processing method and device, storage medium and electronic device

Country Status (1)

Country Link
CN (1) CN117579409A (en)

Similar Documents

Publication Publication Date Title
CN114697150B (en) Command issuing method and device, storage medium and electronic device
CN114896003A (en) Page configuration method and device, storage medium and electronic device
CN116107975A (en) Control method and device of equipment, storage medium and electronic device
CN116360584A (en) Virtual target product generation method and device, storage medium and electronic device
CN117579409A (en) Control instruction processing method and device, storage medium and electronic device
CN115631832A (en) Cooking plan determination method and device, storage medium and electronic device
CN115345225A (en) Method and device for determining recommended scene, storage medium and electronic device
CN115499333A (en) Method, system, storage medium and electronic device for determining association relationship
US11251985B2 (en) Method for configuring and method for controlling a home automation apparatus
CN116756480A (en) Data statistics method and device, storage medium and electronic device
CN115296958B (en) Distribution method and device of equipment control tasks, storage medium and electronic device
CN117909814A (en) Fault data management method and device, storage medium and electronic device
CN116301767A (en) Interface file generation method and device, storage medium and electronic device
CN116243944A (en) Application interface updating method and device, storage medium and electronic device
CN117768256A (en) Equipment control method, device, storage medium and electronic device
CN115174297A (en) Attribute information updating method and device, storage medium and electronic device
CN116074391A (en) Information transmission method and device, storage medium and electronic device
CN116521673A (en) Database operation method and device, storage medium and electronic device
CN116760792A (en) Gateway message sending method and device, storage medium and electronic device
CN116521767A (en) Data information determining method and device, storage medium and electronic device
CN115145615A (en) Memory data refreshing method and device, storage medium and electronic device
CN117648229A (en) Data monitoring method and device, storage medium and electronic device
CN116132209A (en) Scene construction method and device, storage medium and electronic device
CN117891490A (en) Method, system, electronic equipment and storage medium for configuring components
CN116980439A (en) Label data adjusting method and device, storage medium and electronic device

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