CN110505127B - Instruction processing method and device - Google Patents

Instruction processing method and device Download PDF

Info

Publication number
CN110505127B
CN110505127B CN201910616306.2A CN201910616306A CN110505127B CN 110505127 B CN110505127 B CN 110505127B CN 201910616306 A CN201910616306 A CN 201910616306A CN 110505127 B CN110505127 B CN 110505127B
Authority
CN
China
Prior art keywords
control instruction
instruction
value
moment
control
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910616306.2A
Other languages
Chinese (zh)
Other versions
CN110505127A (en
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 Hisense Hitachi Air Conditioning System Co Ltd
Original Assignee
Qingdao Hisense Hitachi Air Conditioning System 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 Hisense Hitachi Air Conditioning System Co Ltd filed Critical Qingdao Hisense Hitachi Air Conditioning System Co Ltd
Priority to CN201910616306.2A priority Critical patent/CN110505127B/en
Publication of CN110505127A publication Critical patent/CN110505127A/en
Application granted granted Critical
Publication of CN110505127B publication Critical patent/CN110505127B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • FMECHANICAL ENGINEERING; LIGHTING; HEATING; WEAPONS; BLASTING
    • F24HEATING; RANGES; VENTILATING
    • F24FAIR-CONDITIONING; AIR-HUMIDIFICATION; VENTILATION; USE OF AIR CURRENTS FOR SCREENING
    • F24F11/00Control or safety arrangements
    • F24F11/50Control or safety arrangements characterised by user interfaces or communication
    • F24F11/56Remote control
    • F24F11/58Remote control using Internet communication
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B15/00Systems controlled by a computer
    • G05B15/02Systems controlled by a computer electric
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B19/00Programme-control systems
    • G05B19/02Programme-control systems electric
    • G05B19/418Total factory control, i.e. centrally controlling a plurality of machines, e.g. direct or distributed numerical control [DNC], flexible manufacturing systems [FMS], integrated manufacturing systems [IMS] or computer integrated manufacturing [CIM]
    • 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
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B2219/00Program-control systems
    • G05B2219/20Pc systems
    • G05B2219/26Pc applications
    • G05B2219/2642Domotique, domestic, home control, automation, smart house
    • 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
    • H04L2012/2847Home automation networks characterised by the type of home appliance used
    • H04L2012/285Generic home appliances, e.g. refrigerators

Landscapes

  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Physics & Mathematics (AREA)
  • Combustion & Propulsion (AREA)
  • Mechanical Engineering (AREA)
  • Computing Systems (AREA)
  • Chemical & Material Sciences (AREA)
  • Human Computer Interaction (AREA)
  • Manufacturing & Machinery (AREA)
  • Quality & Reliability (AREA)
  • Selective Calling Equipment (AREA)

Abstract

The embodiment of the invention discloses an instruction processing method and device, relates to the field of smart home, and solves the problems that an air conditioner fails and user experience is poor due to the fact that the air conditioner frequently responds to a control instruction in a short time due to misoperation. The specific scheme is as follows: receiving a control instruction sent by a terminal, wherein the control instruction is used for controlling household equipment connected with an instruction processing device, recording a first moment when the control instruction is received, and determining that the control instruction is an abnormal instruction when the difference value between the first moment and a second moment is less than or equal to a first preset time; and the second moment is the time of receiving the previous control instruction of the control instruction, and the control instruction is filtered. The embodiment of the invention is used in the process of processing the received control instruction by the instruction processing device.

Description

Instruction processing method and device
Technical Field
The embodiment of the invention relates to the field of smart home, in particular to a method and a device for processing an instruction.
Background
Currently, an air conditioner may access an intelligent home platform (i.e., HomeKit platform) through a protocol conversion device, such as a gateway. Therefore, the user can remotely control the air conditioner and monitor the running state of the air conditioner by operating the intelligent home platform.
For example, when a user needs to remotely control the on or off of an air conditioner, the method can be operated in an intelligent home platform application installed on the terminal. The terminal can send a control instruction to the gateway according to the operation of the user, and the gateway sends the control instruction to the indoor unit of the air conditioner after protocol conversion so as to control the air conditioner to be turned on or turned off. However, if the user has a malfunction on the terminal or repeatedly clicks the power-on or power-off button, the terminal will continuously send control commands to the indoor unit via the gateway, so that the indoor unit receives a plurality of control commands in a short time and performs repeated power-on and power-off. This may cause the air conditioner to malfunction, and also may cause a user experience to be poor.
Disclosure of Invention
The invention provides an instruction processing method and device, and solves the problems that an air conditioner fails and user experience is poor due to the fact that the air conditioner frequently responds to a control instruction in a short time due to misoperation.
In order to achieve the purpose, the invention adopts the following technical scheme:
in a first aspect, the present invention provides an instruction processing method applied to an instruction processing apparatus. The instruction processing method may include: receiving a control instruction sent by a terminal, wherein the control instruction is used for controlling the household equipment connected with the instruction processing device; recording a first moment when a control instruction is received; when the difference value between the first moment and the second moment is determined to be less than or equal to first preset time, determining the control instruction as an abnormal instruction; the second moment is the time of receiving the previous control instruction of the control instruction; and filtering the control command.
With reference to the first aspect, in a possible implementation manner, the method may further include: when the difference value between the first moment and the second moment is determined to be larger than the first preset time, judging whether the difference value between the first moment and the third moment is smaller than or equal to the second preset time; the second preset time is longer than the first preset time, the control instruction is the Nth received control instruction, the third moment is the time for receiving the (N-K) th control instruction, K is an integer larger than or equal to 1, and N is an integer larger than K; if not, sending a control instruction to the household equipment; if yes, sending a control instruction to the household equipment when the Nth control instruction is determined to be different from the (N-K) th control instruction.
With reference to the first aspect and the foregoing possible implementation manners, in another possible implementation manner, the method may further include: determining the value of a zone bit when the Nth control instruction is the same as the (N-K) th control instruction; the flag bit comprises a first value or a second value, the first value is used for indicating a filtering control instruction, and the second value is used for indicating a response control instruction; and if the flag bit is the second value, sending a control instruction to the household equipment, and setting the flag bit from the second value to the first value.
With reference to the first aspect and the foregoing possible implementation manners, in another possible implementation manner, the method may further include: if the flag bit is a first value, the control instruction is filtered.
In a second aspect, the present invention provides an instruction processing apparatus, which may include: the device comprises a receiving unit, a storage unit, a determining unit and a processing unit. The receiving unit is used for receiving a control instruction sent by the terminal, and the control instruction is used for controlling the household equipment connected with the instruction processing device; the storage unit is used for recording the first moment when the control instruction is received; the determining unit is used for determining the control instruction as an abnormal instruction when the difference value between the first time and the second time is less than or equal to a first preset time; the second moment is the time of receiving the previous control instruction of the control instruction; and the processing unit is used for filtering the control instruction.
With reference to the second aspect, in a possible implementation manner, the instruction processing apparatus further includes: a judging unit and a transmitting unit. The judging unit is used for judging whether the difference value between the first moment and the third moment is less than or equal to a second preset time or not when the difference value between the first moment and the second moment is determined to be greater than the first preset time; the second preset time is longer than the first preset time, the control instruction is the Nth received control instruction, the third moment is the time for receiving the (N-K) th control instruction, K is an integer larger than or equal to 1, and N is an integer larger than K; the sending unit is used for sending a control instruction to the household equipment if the control instruction is not sent; if yes, sending a control instruction to the household equipment when the Nth control instruction is determined to be different from the (N-K) th control instruction.
With reference to the second aspect and the foregoing possible implementation manners, in another possible implementation manner, the determining unit is further configured to determine the value of the flag bit when it is determined that the nth control instruction is the same as the (N-K) th control instruction; the flag bit comprises a first value or a second value, the first value is used for indicating a filtering control instruction, and the second value is used for indicating a response control instruction; the sending unit is further used for sending a control instruction to the household equipment if the flag bit is the second value; and the processing unit is also used for setting the flag bit to be the first value from the second value.
With reference to the second aspect and the foregoing possible implementation manners, in another possible implementation manner, the processing unit is further configured to filter the control instruction if the flag bit is the first value.
Specific implementation manners may refer to behavior functions of the instruction processing apparatus in the instruction processing method provided in the first aspect or possible implementation manners of the first aspect.
In a third aspect, an instruction processing apparatus is provided, which includes: at least one processor, a memory, a communication interface, and a communication bus. The processor is connected with the memory and the communication interface through a communication bus, the memory is used for storing computer execution instructions, and when the instruction processing device runs, the processor executes the computer execution instructions stored in the memory, so that the instruction processing device executes the instruction processing method according to the first aspect or any one of the possible implementation manners of the first aspect.
In a fourth aspect, a computer storage medium is provided, on which computer executable instructions are stored, which, when executed on an instruction processing apparatus, cause the instruction processing apparatus to perform the instruction processing method as the first aspect or any one of the possible implementations of the first aspect.
In the instruction processing method, an instruction processing device, such as a gateway, records a first time when a control instruction is received after the control instruction sent by a terminal is received, determines the control instruction as an abnormal instruction when the time between the first time and the time when the control instruction is received before the control instruction, namely the difference value of a second time is less than or equal to a first preset time, and filters the control instruction. Therefore, the difference value between the time when the current control instruction is received and the time when the previous control instruction is received is compared with the first preset time, and the first preset time period prestored in the gateway is short, so that the situation that the control instructions are abnormal is considered to occur when the control instructions are received in the short time period, when the difference value is determined to be smaller than the first preset time, the current control instruction is determined to be the abnormal instruction, the abnormal instruction is not sent to the household equipment, the gateway can effectively filter the abnormal instruction, the problem that the household equipment frequently responds to the control instruction in a short time is avoided, the effect of protecting the household equipment is achieved, and the user experience is improved.
Drawings
Fig. 1 is a simplified schematic diagram of a system architecture to which an embodiment of the present invention may be applied;
FIG. 2 is a block diagram of an instruction processing apparatus according to an embodiment of the present invention;
FIG. 3 is a flowchart of a method for processing instructions according to an embodiment of the present invention;
FIG. 4 is a diagram illustrating an exemplary embodiment of an instruction processing apparatus for processing instructions;
FIG. 5 is a diagram illustrating processing of instructions by an instruction processing apparatus according to another embodiment of the present invention;
FIG. 6 is a flowchart of another instruction processing method according to an embodiment of the present invention;
FIG. 7 is a diagram illustrating processing of instructions by an instruction processing apparatus according to another embodiment of the present invention;
FIG. 8 is a diagram illustrating processing of instructions by an instruction processing apparatus according to another embodiment of the present invention;
FIG. 9 is a block diagram of another exemplary instruction processing apparatus;
FIG. 10 is a block diagram of an instruction processing apparatus according to another embodiment of the present invention;
FIG. 11 is a block diagram of another instruction processing apparatus according to an embodiment of the present invention.
Detailed Description
The terms "system" and "network" are often used interchangeably herein. The term "and/or" herein is merely an association describing an associated object, meaning that three relationships may exist, e.g., a and/or B, may mean: a exists alone, A and B exist simultaneously, and B exists alone. In addition, the character "/" herein generally indicates that the former and latter related objects are in an "or" relationship.
Fig. 1 is a simplified schematic diagram of a system architecture to which an embodiment of the present invention may be applied, as shown in fig. 1, the system architecture may include: terminal 11, instruction processing device 12 and household equipment 13.
The instruction processing device 12 may communicate with the terminal 11 by using bluetooth, data traffic, Wireless Fidelity (WiFi), and the like. When the bluetooth and data traffic mode is adopted, the instruction processing device 12 is in direct communication with the terminal 11; when the WiFi mode is used, the instruction processing device 12 and the terminal 11 communicate indirectly through a local WiFi router. And the instruction processing device 12 communicates directly with the household equipment 13 by means of wired connection.
The terminal 11, which is usually installed with an intelligent Home platform application, such as a Home application, may provide unified operation interface management, and is configured to send a control instruction to the instruction processing device 12, so as to implement remote control of the Home device 13; and is further configured to receive the operation state parameters of the home equipment 13 sent by the home equipment 13 through the instruction processing device 12.
In a specific implementation, the triggering condition for the terminal 11 to send the control instruction to the instruction processing device 12 may be that the user performs an operation by means of voice control or touching a screen, or that the terminal 11 receives indication information sent by an accessory connected thereto, such as a temperature sensor.
The instruction processing device 12 may specifically be a protocol conversion device, such as a HomeKit gateway. The gateway is configured to convert a protocol supported by the smart home platform into a protocol supported by the home device 13, process a control instruction received from the terminal 11 to determine whether the control instruction is an abnormal instruction, filter the control instruction if the control instruction is an abnormal instruction, send the control instruction to the home device 13 after performing protocol conversion if the control instruction is not an abnormal instruction, and periodically send a query request to the home device 13 to obtain an operation state of the home device 13 in real time if the control instruction is not present. In fig. 1, the instruction processing device 12 is shown as an example of a gateway.
The home device 13 may be an indoor unit of an air conditioner, a refrigerator, a television, or other devices that can be remotely controlled through an intelligent home platform.
Fig. 2 is a schematic diagram illustrating a composition of an instruction processing apparatus according to an embodiment of the present invention, and as shown in fig. 2, the instruction processing apparatus may include: at least one processor 21, a memory 22, a communication interface 23, and a communication bus 24.
The following specifically describes each constituent element of the instruction processing apparatus with reference to fig. 2:
the processor 21 is a control center of the instruction processing apparatus, and may be a single processor or a collective term for a plurality of processing elements. For example, the processor 21 is a Central Processing Unit (CPU), or may be an Application Specific Integrated Circuit (ASIC), or may be one or more integrated circuits configured to implement embodiments of the present invention, such as: one or more Digital Signal Processors (DSPs), or one or more Field Programmable Gate Arrays (FPGAs).
In particular implementations, processor 21 may include one or more CPUs such as CPU0 and CPU1 shown in fig. 2 as one example. Also, for one embodiment, the instruction processing apparatus may include a plurality of processors, such as processor 21 and processor 25 shown in FIG. 2. Each of these processors may be a single-Core Processor (CPU) or a multi-Core Processor (CPU). A processor herein may refer to one or more devices, circuits, and/or processing cores for processing data (e.g., computer program instructions).
The memory 22 may be, but is not limited to, a read-only memory (ROM) or other type of static storage device that can store static information and instructions, a Random Access Memory (RAM) or other type of dynamic storage device that can store information and instructions, an electrically erasable programmable read-only memory (EEPROM), a compact disk read-only memory (CD-ROM) or other optical disk storage, optical disk storage (including compact disk, laser disk, optical disk, digital versatile disk, blu-ray disk, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer. The memory 22 may be self-contained and coupled to the processor 21 via a communication bus 24. The memory 22 may also be integrated with the processor 21.
In a particular implementation, the memory 22 is used for storing data in the present invention and software programs for implementing the present invention. Also, the processor 21 may perform various functions of the instruction processing apparatus by running or executing a software program stored in the memory 22 and calling data stored in the memory 22.
The communication interface 23 is a device using any transceiver or the like, and is used for communicating with other devices or communication networks, such as a terminal, a home device, a Radio Access Network (RAN), a Wireless Local Area Network (WLAN), and the like. The communication interface 23 may include a receiving unit implementing a receiving function and a transmitting unit implementing a transmitting function.
The communication bus 24 may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, an extended ISA (enhanced industry standard architecture) bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown in FIG. 2, but it is not intended that there be only one bus or one type of bus.
In order to solve the problems that the air conditioner frequently responds to a control instruction in a short time due to misoperation, so that the air conditioner fails and user experience is poor, an embodiment of the present invention provides an instruction processing method, as shown in fig. 3, the method may include:
301. and receiving a control instruction sent by the terminal.
The control instruction is used for controlling the household equipment connected with the instruction processing device. When the household equipment needs to be controlled through the intelligent household platform application installed on the terminal, the control button in the application can be triggered through modes of user operation or linkage indication of accessories connected with the terminal and the like, so that the terminal can send a control instruction to an instruction processing device corresponding to the household equipment, for example, a gateway, and the instruction processing device can receive the control instruction. When the terminal communicates in a WiFi mode, the instruction processing device receives a control instruction sent by the terminal through a local WiFi router; when the terminal communicates in a Bluetooth or data flow mode, the instruction processing device directly receives the control instruction sent by the terminal.
302. And recording the first time when the control instruction is received.
After receiving the control command, the command processing apparatus may parse the control command into a command prompt (CMD) format command, and record a first time when the control command is received.
303. And when the difference value between the first moment and the second moment is determined to be less than or equal to the first preset time, determining that the control instruction is an abnormal instruction.
After recording the first time when the control instruction is received, the instruction processing device may determine whether a difference between the first time and a time when the instruction processing device receives a previous control instruction of the control instruction, that is, a second time is less than or equal to a first preset time. The first preset time pre-stored in the instruction processing device is a short time period obtained by analyzing the actual operation behavior of the user, and one control instruction is received as normal and a plurality of control instructions are received as abnormal in the first preset time period. Therefore, if the difference is less than or equal to the first preset time, the instruction processing apparatus determines that the control instruction is an abnormal instruction, at which point the following step 304 may be performed. If the difference is greater than the first preset time, the instruction processing device may send the control instruction to the corresponding home device after performing the protocol conversion, so as to control the home device.
304. And filtering the control command.
The command processing device filters the control command, namely the control command is not sent to the household equipment.
Illustratively, as shown in fig. 4, assume that the control instructions may include: starting up, shutting down and mode selection, different control instructions are represented by different fillers in fig. 4, and then the terminal can receive the control instructions through the instruction processing device after sending the control instructions to the instruction processing device. Assuming that the received current control command is the nth control command, the command processing apparatus may calculate a difference value t between a time t1 when the nth control command is received and a time t0 when the (N-1) th control command is received, and compare the difference value t with the first preset time a. If the difference t is less than the first preset time a, the instruction processing device filters the control instruction, as shown by a in fig. 4. If the difference t is greater than the first preset time a, the instruction processing device processes the control instruction, as shown by B in fig. 4.
It should be noted that, in the embodiment of the present invention, assuming that the nth control instruction is a filtered control instruction and the (N-1) th control instruction is a processed control instruction, the instruction processing device may filter out other control instructions received within a first preset time period that starts with a time when the (N-1) th control instruction is received, that is, only execute the (N-1) th control instruction. And in the next first preset time period, if the instruction processing device still receives a plurality of control instructions, the control instructions can be filtered out, as shown in fig. 5.
Further, in the embodiment of the present invention, in order to determine the abnormal instruction more accurately, when the instruction processing apparatus determines that the difference between the first time and the second time is greater than the first preset time, as shown in fig. 6, the following steps may be further performed:
305. and when the difference value between the first moment and the second moment is determined to be greater than the first preset time, judging whether the difference value between the first moment and the third moment is less than or equal to the second preset time.
The control instruction is the Nth received control instruction, the third time is the time for receiving the (N-K) th control instruction, K is an integer greater than or equal to 1, and N is an integer greater than K.
When determining that the difference value between the first time and the second time is greater than the first preset time, the instruction processing device may determine whether the control instruction satisfies a certain rule within a time period greater than the first preset time, if so, may process the control instruction satisfying the certain rule once, and filter the subsequent control instruction satisfying the rule. Specifically, the instruction processing device may first determine whether a difference between the first time and the third time is less than or equal to a second preset time, where the second preset time is greater than the first preset time.
For example, when K is 1, the third time is equal to the second time, and the instruction processing device determines whether a difference between a time when the nth control instruction is received and a time when the (N-1) th control instruction is received is less than or equal to a second preset time. And when K is 2, the instruction processing device judges whether the difference value between the time of receiving the Nth control instruction and the time of receiving the (N-2) th control instruction is less than or equal to a second preset time.
Note that the second preset time is a value related to the size of K, which is obtained by analyzing the behavior of the user.
306. And if the difference value is greater than the second preset time, sending a control instruction to the household equipment.
If the difference between the first time and the third time is greater than the second preset time, it is indicated that the nth control instruction is a normal instruction, and at this time, the instruction processing device may send the control instruction to the home equipment after performing protocol conversion.
307. And if the difference is smaller than or equal to the second preset time, judging whether the Nth control instruction is the same as the (N-K) th control instruction.
If the difference between the first time and the third time is less than or equal to a second preset time, the instruction processing device may determine whether the control instruction in the second preset time period satisfies a certain rule by determining whether the nth control instruction is the same as the (N-K) th control instruction.
308. And if the difference is not the same, sending a control instruction to the household equipment.
If the nth control instruction is different from the (N-K) th control instruction, it is indicated that the control instruction in the second preset time period does not satisfy a certain rule, and is a normal instruction, and at this time, the instruction processing device may send the current control instruction to the home equipment after performing protocol conversion, and determine the value of the flag bit. The flag bit is used to indicate whether a control instruction meeting a certain rule is the first occurrence. Specifically, the flag bit may include a first value or a second value, where when the control instruction meeting a certain rule does not occur for the first time, the flag bit is the first value and is used to indicate the filtering control instruction; and when the control instruction meeting a certain rule is the first occurrence, the flag bit has a second value and is used for indicating response to the control instruction. In a specific implementation, the initial value of the flag bit is a second value. For example, the first value may be 1 and the second value may be 0.
If the flag bit is the second value, the instruction processing apparatus does not perform any operation. If the flag bit is the first value, it indicates that the control instruction before the received current control instruction is the control instruction that satisfies a certain rule and has been processed once, and at this time, the instruction processing apparatus may set the flag bit from the first value to the second value.
For example, as shown in fig. 7, if K is 2, and if the difference between the time when the nth control command is received and the time when the (N-2) th control command is received is less than the second preset time b, the nth control command is different from the (N-2) th control command, and the command processing apparatus processes the control command normally.
309. If the two are the same, the value of the flag bit is determined.
If the nth control instruction is the same as the (N-K) th control instruction, it indicates that the control instruction in the second preset time period satisfies a certain rule, and the control instruction is an abnormal instruction, and at this time, the instruction processing device may determine the value of the flag bit.
310. And if the flag bit is the second value, sending a control instruction to the household equipment, and setting the flag bit from the second value to the first value.
If the flag bit is the second value, the instruction processing device can perform protocol conversion and send a control instruction to the household equipment, and the flag bit is set to the first value from the second value so as to indicate that the control instruction meeting a certain rule has been processed once.
311. If the flag bit is a first value, the control instruction is filtered.
If the flag bit is the first value, the instruction processing device may determine that the current control instruction is an abnormal instruction meeting a certain rule, and the control instruction may be filtered when the current control instruction has been processed once.
For example, assuming that K is 2 and assuming that a difference between a time when the nth control command is received and a time when the (N-2) th control command is received is less than a second preset time b, the nth control command is the same as the (N-2) th control command, as shown by A, B and C in fig. 8, the command processing apparatus may process the nth control command, the (N-1) th control command, and the (N-2) th control command once.
In the instruction processing method, an instruction processing device, such as a gateway, records a first time when a control instruction is received after the control instruction sent by a terminal is received, determines the control instruction as an abnormal instruction when the time between the first time and the time when the control instruction is received before the control instruction, namely the difference value of a second time is less than or equal to a first preset time, and filters the control instruction. Therefore, the difference value between the time when the current control instruction is received and the time when the previous control instruction is received is compared with the first preset time, and the first preset time period prestored in the gateway is short, so that the situation that the control instructions are abnormal is considered to occur when the control instructions are received in the short time period, when the difference value is determined to be smaller than the first preset time, the current control instruction is determined to be the abnormal instruction, the abnormal instruction is not sent to the household equipment, the gateway can effectively filter the abnormal instruction, the problem that the household equipment frequently responds to the control instruction in a short time is avoided, the effect of protecting the household equipment is achieved, and the user experience is improved.
In addition, compared with the prior art that the command processing device such as the gateway filters abnormal commands and prevents misoperation of a user through anti-shake operation, the command processing device can effectively solve misoperation caused by abnormal linkage of accessories. Compared with the abnormal filtering instruction of the household equipment in the prior art, the abnormal filtering instruction of the household equipment can cause that the running parameters of the household equipment can not be fed back in time, and the gateway filtering instruction can not have the problem.
The above description mainly introduces the solution provided by the embodiment of the present invention from the perspective of an instruction processing apparatus. It is understood that the instruction processing apparatus includes hardware structures and/or software modules for performing the respective functions in order to realize the above functions. Those of skill in the art will readily appreciate that the present invention can be implemented in hardware or a combination of hardware and computer software, in conjunction with the exemplary algorithm steps described in connection with the embodiments disclosed herein. Whether a function is performed as hardware or computer software drives hardware depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
In the embodiment of the present invention, the instruction processing apparatus may be divided into the functional modules according to the above-mentioned example of the instruction processing method, for example, each functional module may be divided corresponding to each function, or two or more functions may be integrated into one processing module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. It should be noted that, the division of the modules in the embodiment of the present invention is schematic, and is only a logic function division, and there may be another division manner in actual implementation.
In the case of dividing each functional module by corresponding functions, fig. 9 shows another possible composition diagram of the instruction processing apparatus related in the above embodiment, as shown in fig. 9, the instruction processing apparatus may include: a receiving unit 41, a storage unit 42, a determination unit 43 and a processing unit 44.
Wherein, the receiving unit 41 is configured to support the instruction processing apparatus to execute step 301 in the instruction processing method shown in fig. 3.
The storage unit 42 is used for supporting the instruction processing apparatus to execute step 302 in the instruction processing method shown in fig. 3.
A determining unit 43 for supporting the instruction processing apparatus to execute step 303 in the instruction processing method shown in fig. 3 and step 309 in the instruction processing method shown in fig. 6.
The processing unit 44 is configured to support the instruction processing apparatus to execute step 304 in the instruction processing method shown in fig. 3, and set the flag bit from the second value to the first value as described in step 310 in the instruction processing method shown in fig. 6, step 311.
In this embodiment of the present invention, further, as shown in fig. 10, the instruction processing apparatus may further include: a judging unit 45 and a transmitting unit 46.
The determining unit 45 is configured to support the instruction processing apparatus to execute step 305 and step 307 in the instruction processing method shown in fig. 6.
The sending unit 46 is configured to support the instruction processing device to execute sending of the control instruction to the home equipment in steps 306, 308, and 310 in the instruction processing method shown in fig. 6.
It should be noted that all relevant contents of each step related to the above embodiment of the instruction processing method may be referred to the functional description of the corresponding functional module, and are not described herein again.
The instruction processing apparatus provided by the embodiment of the invention is used for executing the instruction processing method, so that the same effect as the instruction processing method can be achieved.
Fig. 11 shows another possible schematic composition diagram of the instruction processing apparatus involved in the above-described embodiment, in the case of using an integrated unit. As shown in fig. 11, the instruction processing apparatus includes: a processing module 51, a communication module 52 and a storage module 53.
The processing module 51 is used for controlling and managing actions of the instruction processing apparatus, for example, the processing module 51 is used for supporting the instruction processing apparatus to execute step 303, step 304 in fig. 3, step 305, step 307, step 309, step 310 in fig. 6, set the flag bit from the second value to the first value, step 311, and/or other processes for the techniques described herein. The communication module 52 is used to support the instruction processing apparatus to communicate with other network entities, such as terminals and home devices. For example, the communication module 52 is configured to support the instruction processing device to execute step 301 in fig. 3, and send the control instruction to the home device in steps 306, 308, and 310 in fig. 6. A storage module 53 for storing program codes and data of the instruction processing apparatus. For example, the storage module 53 is used to support the instruction processing apparatus to execute step 302 in fig. 3.
The processing module 51 may be the processor in fig. 2. Which may implement or perform the various illustrative logical blocks, modules, and circuits described in connection with the disclosure. A processor may also be a combination of computing functions, e.g., comprising one or more microprocessors, a DSP and a microprocessor, or the like. The communication module 52 may be the communication interface in fig. 2. The storage module 53 may be the memory in fig. 2.
Through the above description of the embodiments, it is clear to those skilled in the art that, for convenience and simplicity of description, the foregoing division of the functional modules is merely used as an example, and in practical applications, the above function distribution may be completed by different functional modules according to needs, that is, the internal structure of the device may be divided into different functional modules to complete all or part of the above described functions.
In the embodiments provided in the present invention, it should be understood that the disclosed apparatus and instruction processing method may be implemented in other ways. For example, the above-described device embodiments are merely illustrative, and for example, the division of the modules or units is only one logical functional division, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or may be integrated into another device, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may be one physical unit or a plurality of physical units, that is, may be located in one place, or may be distributed in a plurality of different places. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a readable storage medium. Based on such understanding, the technical solution of the embodiments of the present invention may be essentially or partially contributed to by the prior art, or all or part of the technical solution may be embodied in the form of a software product, where the software product is stored in a storage medium and includes several instructions to enable a device (which may be a single chip, a chip, or the like) or a processor (processor) to execute all or part of the steps of the instruction processing method according to the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a U disk, a removable hard disk, a ROM, a RAM, a magnetic disk, or an optical disk.
The above description is only an embodiment of the present invention, but the scope of the present invention is not limited thereto, and any changes or substitutions within the technical scope of the present invention are intended to be covered by the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the appended claims.

Claims (10)

1. An instruction processing method applied to an instruction processing device, the method comprising:
receiving a control instruction sent by a terminal, wherein the control instruction is used for controlling the household equipment connected with the instruction processing device;
recording a first moment when the control instruction is received;
when the difference value between the first moment and the second moment is determined to be less than or equal to first preset time, determining that the control instruction is an abnormal instruction; the second moment is the time of receiving a previous control instruction of the control instructions;
and filtering the control instruction.
2. The instruction processing method of claim 1, further comprising:
when the difference value between the first moment and the second moment is determined to be greater than the first preset time, judging whether the difference value between the first moment and the third moment is less than or equal to the second preset time; the second preset time is longer than the first preset time, the control instruction is the Nth received control instruction, the third moment is the time for receiving the (N-K) th control instruction, K is an integer larger than or equal to 1, and N is an integer larger than K;
if not, sending the control instruction to the household equipment;
if yes, sending the control instruction to the household equipment when the Nth control instruction is determined to be different from the (N-K) th control instruction.
3. The instruction processing method according to claim 2, further comprising:
determining the value of a flag bit when the Nth control instruction is the same as the (N-K) th control instruction; the flag bit comprises a first value or a second value, the first value is used for indicating that the control instruction is filtered, and the second value is used for indicating that the control instruction is responded;
and if the flag bit is the second value, sending the control instruction to the household equipment, and setting the flag bit to be the first value from the second value.
4. The instruction processing method of claim 3, further comprising:
and if the flag bit is the first value, filtering the control instruction.
5. An instruction processing apparatus, characterized in that the instruction processing apparatus comprises: the device comprises a receiving unit, a storage unit, a determining unit and a processing unit;
the receiving unit is used for receiving a control instruction sent by a terminal, and the control instruction is used for controlling the household equipment connected with the instruction processing device;
the storage unit is used for recording a first moment when the control instruction is received;
the determining unit is used for determining the control instruction as an abnormal instruction when the difference value between the first time and the second time is determined to be less than or equal to a first preset time; the second moment is the time of receiving a previous control instruction of the control instructions;
the processing unit is used for filtering the control instruction.
6. The instruction processing apparatus according to claim 5, further comprising: a judging unit and a transmitting unit;
the judging unit is used for judging whether the difference value between the first moment and the third moment is less than or equal to a second preset time or not when the difference value between the first moment and the second moment is determined to be greater than the first preset time; the second preset time is longer than the first preset time, the control instruction is the Nth received control instruction, the third moment is the time for receiving the (N-K) th control instruction, K is an integer larger than or equal to 1, and N is an integer larger than K;
the sending unit is used for sending the control instruction to the household equipment if the control instruction is not sent; if yes, sending the control instruction to the household equipment when the Nth control instruction is determined to be different from the (N-K) th control instruction.
7. The instruction processing apparatus of claim 6,
the determination unit is further configured to determine a value of a flag bit when it is determined that the nth control instruction is the same as the (N-K) th control instruction; the flag bit comprises a first value or a second value, the first value is used for indicating that the control instruction is filtered, and the second value is used for indicating that the control instruction is responded;
the sending unit is further configured to send the control instruction to the home equipment if the flag bit is the second value;
the processing unit is further configured to set the flag bit from the second value to the first value.
8. The instruction processing apparatus of claim 7,
the processing unit is further configured to filter the control instruction if the flag bit is the first value.
9. An instruction processing apparatus, characterized in that the instruction processing apparatus comprises: at least one processor, a memory, a communication interface, and a communication bus;
the processor is connected with the memory and the communication interface through the communication bus, the memory is used for storing computer execution instructions, and when the instruction processing device runs, the processor executes the computer execution instructions stored in the memory so as to enable the instruction processing device to execute the instruction processing method according to any one of claims 1-4.
10. A computer storage medium comprising computer executable instructions which, when run on an instruction processing apparatus, cause the instruction processing apparatus to perform the instruction processing method of any one of claims 1-4.
CN201910616306.2A 2019-07-09 2019-07-09 Instruction processing method and device Active CN110505127B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910616306.2A CN110505127B (en) 2019-07-09 2019-07-09 Instruction processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910616306.2A CN110505127B (en) 2019-07-09 2019-07-09 Instruction processing method and device

Publications (2)

Publication Number Publication Date
CN110505127A CN110505127A (en) 2019-11-26
CN110505127B true CN110505127B (en) 2021-09-28

Family

ID=68586153

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910616306.2A Active CN110505127B (en) 2019-07-09 2019-07-09 Instruction processing method and device

Country Status (1)

Country Link
CN (1) CN110505127B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114508835A (en) * 2020-11-16 2022-05-17 青岛海信电子产业控股股份有限公司 Terminal and air conditioner mode adjusting method
CN113032313B (en) * 2021-02-08 2024-04-26 珠海奔图电子有限公司 Data receiving method, apparatus, image forming device, and readable storage medium

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103873112A (en) * 2014-03-04 2014-06-18 北京世壮物联科技有限公司 Intelligent power line carrier synchronous control method
CN105388779A (en) * 2015-12-25 2016-03-09 小米科技有限责任公司 Control method and device for intelligent equipment
CN105867142A (en) * 2016-03-30 2016-08-17 宁波三博电子科技有限公司 Intelligent home control method and system based on two-way interaction
EP3067712A1 (en) * 2013-11-06 2016-09-14 Samsung Electronics Co., Ltd. Position estimation device and method for wireless communication system
CN106027341A (en) * 2016-06-21 2016-10-12 杭州古北电子科技有限公司 Control method of smart home device
CN106896747A (en) * 2017-01-22 2017-06-27 无锡小天鹅股份有限公司 Household electric appliance control method, device and mobile terminal
CN107770152A (en) * 2017-09-01 2018-03-06 珠海格力电器股份有限公司 A kind of safety protection method and device, electrical equipment, server and storage medium
CN109798634A (en) * 2019-01-30 2019-05-24 海信家电集团股份有限公司 A kind of Defrost method and air conditioner of air conditioner

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI502583B (en) * 2013-04-11 2015-10-01 Wistron Corp Apparatus and method for voice processing

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP3067712A1 (en) * 2013-11-06 2016-09-14 Samsung Electronics Co., Ltd. Position estimation device and method for wireless communication system
CN103873112A (en) * 2014-03-04 2014-06-18 北京世壮物联科技有限公司 Intelligent power line carrier synchronous control method
CN105388779A (en) * 2015-12-25 2016-03-09 小米科技有限责任公司 Control method and device for intelligent equipment
CN105867142A (en) * 2016-03-30 2016-08-17 宁波三博电子科技有限公司 Intelligent home control method and system based on two-way interaction
CN106027341A (en) * 2016-06-21 2016-10-12 杭州古北电子科技有限公司 Control method of smart home device
CN106896747A (en) * 2017-01-22 2017-06-27 无锡小天鹅股份有限公司 Household electric appliance control method, device and mobile terminal
CN107770152A (en) * 2017-09-01 2018-03-06 珠海格力电器股份有限公司 A kind of safety protection method and device, electrical equipment, server and storage medium
CN109798634A (en) * 2019-01-30 2019-05-24 海信家电集团股份有限公司 A kind of Defrost method and air conditioner of air conditioner

Also Published As

Publication number Publication date
CN110505127A (en) 2019-11-26

Similar Documents

Publication Publication Date Title
US11799786B2 (en) Device and method for disabling a WLAN hotspot based on data traffic value
JP5714590B2 (en) Remote access of elevator control systems with multiple subsystems
CN110762775B (en) Upgrading method of air conditioner and air conditioner
CN110505127B (en) Instruction processing method and device
US20120246493A1 (en) Protocols for reporting power status over multiple buses
CN108600219B (en) Voice control method and device
CN113746821A (en) Intelligent device control method and device, storage medium and electronic device
JP6502908B2 (en) Slave device
US9582069B2 (en) Electronic apparatus and wake-up method thereof
US11204804B2 (en) Electronic device and control method thereof
US11314670B2 (en) Method, apparatus, and device for transmitting file based on BMC, and medium
US10819256B2 (en) Motor driving method, mobile terminal, and computer-readable storage medium
US11431782B2 (en) Method, apparatus, and device for transmitting file based on BMC, and medium
JP2020017922A (en) Radio communication system
JP4873220B2 (en) Field communication system
CN112214437A (en) Storage device, communication method and device and computer readable storage medium
CN107800677B (en) Apparatus and method for providing adaptive connection service
CN110944063B (en) Programmable logic control device connection method, control system and readable medium
EP3096494B1 (en) Control method, controller, and recording medium
JP2003199180A (en) Device controller and method, device control system
CN112181708B (en) Method and device for controlling load based on frequency converter error code rate
US11809533B2 (en) Control device
CN110311815B (en) Method, device, equipment and storage medium for realizing switching of Ethernet working mode
CN115981924B (en) Device control method, electronic device and storage medium
JP2024036207A (en) Communication equipment and in-vehicle systems

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant