CN110557448A - Control method and system for smart home - Google Patents

Control method and system for smart home Download PDF

Info

Publication number
CN110557448A
CN110557448A CN201910810482.XA CN201910810482A CN110557448A CN 110557448 A CN110557448 A CN 110557448A CN 201910810482 A CN201910810482 A CN 201910810482A CN 110557448 A CN110557448 A CN 110557448A
Authority
CN
China
Prior art keywords
control
local host
cloud platform
communication
gateway device
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
CN201910810482.XA
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.)
THINKHOME Co Ltd
Original Assignee
THINKHOME 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 THINKHOME Co Ltd filed Critical THINKHOME Co Ltd
Priority to CN201910810482.XA priority Critical patent/CN110557448A/en
Publication of CN110557448A publication Critical patent/CN110557448A/en
Pending legal-status Critical Current

Links

Classifications

    • 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], computer integrated manufacturing [CIM]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/66Arrangements for connecting between networks having differing types of switching systems, e.g. gateways
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/10Active monitoring, e.g. heartbeat, ping or trace-route
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/12Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
    • H04L67/125Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks involving control of end-device applications over a network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/16Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
    • 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
    • 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 invention provides a control system and a control method for smart home, which relate to the technical field of equipment networking control and comprise the following steps that a gateway device detects a heartbeat packet in a network in real time: if the heartbeat packet is detected, the gateway equipment establishes communication connection with the cloud platform, receives a control instruction sent by the cloud platform to control each terminal equipment, and receives an inquiry instruction sent by the cloud platform to acquire real-time state information of each terminal equipment; if the heartbeat packet is not detected, the gateway device counts the duration of the undetected heartbeat packet, and compares the duration with a preset duration threshold: if the duration is not less than the duration threshold, the gateway device establishes communication connection with the local host, receives a control instruction sent by the local host to control each terminal device, and receives an inquiry instruction sent by the local host to acquire real-time state information of each terminal device. The invention effectively solves the problem that the intelligent home cannot be controlled and inquired under the condition of network disconnection, and improves the user experience.

Description

control method and system for smart home
Technical Field
the invention relates to the technical field of equipment networking control, in particular to a control method and a control system for smart home.
background
In recent years, the mobile internet is continuously developed at a high speed, the concepts of the internet of things and the internet + are gradually deepened, and related products and services emerge endlessly. Meanwhile, with the development of digital informatization and mobile internet, people are more and more eager to enjoy more convenient, faster, more intelligent and more comfortable digital intelligent home life; compared with the traditional home, the intelligent home has the traditional home function and can provide a more comfortable, safe and high-grade living environment. The intelligent home utilizes advanced computer technology, network communication technology, comprehensive wiring technology and human engineering principle, integrates individual requirements, organically combines subsystems related to home life such as security protection, light control, curtain control, gas valve control, information appliances, scene linkage, floor heating and the like, and converts various devices from a passive structure into an active partner through networked comprehensive intelligent control and management, thereby realizing brand-new home life experience.
the network is the basis of the whole intelligent home system, the existing intelligent home products generally need to depend on the network and are controlled through corresponding software carried by the mobile phone end, once the operator network breaks down, all the intelligent home products cannot be normally used by the part controlled by the internet network, and the use experience of users is seriously influenced.
disclosure of Invention
Aiming at the problems in the prior art, the invention provides a control method of an intelligent home, which specifically comprises the following steps: setting a router in a network, wherein the router is respectively connected with at least one gateway device and a local host, and the gateway device is connected with a plurality of terminal devices;
the control method specifically comprises the following steps:
step S1, the gateway device detects, in real time, the heartbeat packet in the network:
if the heartbeat packet is detected, turning to step S2;
If the heartbeat packet is not detected, turning to step S3;
step S2, the gateway device establishes a communication connection with a cloud platform connected to the router, receives a control instruction sent by the cloud platform to control each terminal device, receives an inquiry instruction sent by the cloud platform to obtain real-time status information of each terminal device, and then returns to step S1;
step S3, the gateway device counts the duration of the heartbeat packet that is not detected, and compares the duration with a preset duration threshold:
if the duration is less than the duration threshold, it indicates that the gateway device is in a networking state, and then returns to the step S2;
if the duration is not less than the duration threshold, indicating that the gateway device is in a disconnected state, and then turning to step S4;
step S4, the gateway device establishes a communication connection with the local host connected to the router, receives a control command sent by the local host to control each of the terminal devices, receives a query command sent by the local host to obtain real-time status information of each of the terminal devices, and then returns to step S1.
Preferably, in step S4, the process of establishing a communication connection between the gateway device and the local host specifically includes:
Step A1, the gateway device switches the communication mode from TCP communication to UDP communication;
step a2, the gateway device sending a broadcast command in the communication mode of the UDP communication to obtain the IP address of the local host;
Step a3, the gateway device switches the communication mode from the UDP communication to the TCP communication mode, and establishes the communication connection with the local host according to the IP address.
preferably, a first control list indicating a correspondence between each of the terminal devices and the control instruction is pre-stored in the cloud platform;
the generation process of the first control list specifically comprises the following steps:
step B1, a mobile terminal connected with the cloud platform binds the corresponding control instruction to each terminal device and uploads the binding result to the cloud platform;
Step B2, the cloud platform generates and stores the first control list according to the binding result;
And the first control list comprises the corresponding relation between each terminal device and the control instruction.
preferably, the method further comprises a process of presetting a local control list, and the local host keeps long connection with the cloud platform;
The process of presetting the local control list specifically includes:
step C1, the local host detects the communication state between the local host and the cloud platform in real time:
if the communication status indicates that the long connection is normal, go to step C2;
If the communication status indicates that the long connection is broken, the local host continuously attempts to reestablish the long connection, and then returns to the step C1;
step C2, the local host acquires the first control list stored in the cloud platform and stores the first control list as the local control list.
preferably, the method further includes a process of updating the local control list, specifically including:
Step D1, the cloud platform receives change information of the corresponding relation between each terminal device and the control instruction, which is uploaded by the mobile terminal, and updates the first control list according to the change information;
And D2, the local host regularly acquires the first control list stored in the cloud platform according to a preset time interval, and updates the local control list according to the first control list.
preferably, the local host and the gateway device are in the same network segment.
A control system of smart home is applied to the control method of smart home, and specifically comprises the following steps:
setting a router in a network, wherein the router is respectively connected with at least one gateway device and a local host, and the gateway device is connected with a plurality of terminal devices;
the gateway device specifically includes:
the first detection module is used for detecting the heartbeat packet in the network in real time, outputting a first detection result when the heartbeat packet is detected, and outputting a second detection result when the heartbeat packet is not detected;
the first control module is connected with the first detection module and used for establishing communication connection with a cloud platform connected with the router according to the first detection result, receiving a control instruction sent by the cloud platform to control each terminal device, and receiving an inquiry instruction sent by the cloud platform to acquire real-time state information of each terminal device;
the timing module is connected with the first detection module and used for counting the duration of the heartbeat packet which is not detected according to the second detection result, comparing the duration with a preset duration threshold and outputting a corresponding judgment result when the duration is not less than the duration threshold;
And the second control module is connected with the timing module and used for establishing communication connection with the local host connected with the router according to the judgment result, receiving a control instruction sent by the local host to control each terminal device, and receiving a query instruction sent by the local host to acquire real-time state information of each terminal device.
preferably, the second control module specifically includes:
The processing unit is used for switching the communication mode from TCP communication to UDP communication according to the judgment result;
The query unit is connected with the processing unit and used for sending a broadcast command in a communication mode of the UDP communication to acquire the IP address of the local host;
And the control unit is connected with the query unit and used for switching the communication mode from the UDP communication to the TCP communication mode and establishing the communication connection with the local host according to the IP address.
Preferably, the mobile terminal is connected to the cloud platform and used for binding each terminal device with a corresponding control instruction and uploading a binding result to the cloud platform.
preferably, the local host specifically includes:
The storage module is used for storing a local control list acquired in advance, and the local control list comprises the terminal equipment and the control instruction corresponding to the terminal equipment;
The second detection module is used for detecting the communication state between the local host and the cloud platform in real time, outputting a corresponding third detection result when the communication state indicates that the long connection is normal, and outputting a corresponding fourth detection result when the communication state indicates that the long connection is disconnected;
And the first control module is respectively connected with the second detection module and the storage module and is used for regularly acquiring a first control list generated in the cloud platform in advance according to the third detection result and a preset time interval and updating the local control list according to the first control list.
And the second control module is connected with the second detection module and used for continuously trying to reestablish the long connection according to the fourth detection result.
the technical scheme has the following advantages or beneficial effects: in a networking state, the gateway equipment establishes communication connection with the cloud platform, receives a control instruction sent by the cloud platform to control each terminal equipment, and receives an inquiry instruction sent by the cloud platform to acquire real-time state information of each terminal equipment; under the condition of network disconnection, the gateway equipment establishes communication connection with the local host, receives a control instruction sent by the local host to control each terminal equipment, and receives a query instruction sent by the local host to acquire real-time state information of each terminal equipment; the problem that the intelligent home cannot be controlled and inquired under the condition of network disconnection is effectively solved, and user experience is improved.
drawings
fig. 1 is a schematic flow chart illustrating a control method of a smart home according to a preferred embodiment of the present invention;
Fig. 2 is a flowchart illustrating a process of establishing a communication connection between a gateway device and a local host according to a preferred embodiment of the present invention;
FIG. 3 is a flow chart illustrating a process of generating a first control list according to a preferred embodiment of the present invention;
FIG. 4 is a flow chart illustrating a process of presetting a local control list according to a preferred embodiment of the present invention;
FIG. 5 is a flow chart illustrating a process of updating a local control list according to a preferred embodiment of the present invention;
fig. 6 is a schematic structural diagram of a control system of a smart home according to a preferred embodiment of the present invention.
Detailed Description
The invention is described in detail below with reference to the figures and specific embodiments. The present invention is not limited to the embodiment, and other embodiments may be included in the scope of the present invention as long as the gist of the present invention is satisfied.
in a preferred embodiment of the present invention, based on the above problems in the prior art, a method for controlling a smart home is provided, which specifically includes: a router is arranged in a network, the router is respectively connected with at least one gateway device and a local host, and the gateway device is connected with a plurality of terminal devices;
As shown in fig. 1, the control method specifically includes:
step S1, the gateway device detects the heartbeat packet in the network in real time:
If a heartbeat packet is detected, go to step S2;
If the heartbeat packet is not detected, the step is turned to step S3;
step S2, the gateway device establishes communication connection with a cloud platform connected with the router, receives a control instruction sent by the cloud platform to control each terminal device, receives an inquiry instruction sent by the cloud platform to acquire real-time state information of each terminal device, and then returns to step S1;
step S3, the gateway device counts the duration of the undetected heartbeat packet, and compares the duration with a preset duration threshold:
if the duration is less than the duration threshold, it indicates that the gateway device is in a networking state, and then returns to step S2;
If the duration is not less than the duration threshold, indicating that the gateway device is in a disconnected state, and then turning to step S4;
in step S4, the gateway device establishes a communication connection with the local host connected to the router, receives a control command sent by the local host to control each terminal device, and receives a query command sent by the local host to obtain real-time status information of each terminal device, and then returns to step S1.
specifically, in this embodiment, the gateway device detects a network connection condition in real time, establishes a communication connection with the cloud platform through the router when the network is normally connected, controls each terminal device connected to the gateway device through a control instruction sent by the cloud platform, and queries real-time state information of each terminal device connected to the gateway device through a query instruction sent by the cloud platform; when the network is disconnected, the router is in communication connection with the local host, the terminal equipment connected with the gateway equipment is controlled through the control instruction sent by the local host, and the real-time state information of the terminal equipment connected with the gateway equipment is inquired through the inquiry instruction sent by the local host, so that the problem that the intelligent home cannot control and inquire the terminal equipment under the condition of network disconnection is effectively solved, and the user experience is improved.
the real-time status information includes the terminal device being in an on or off state and the relevant status data when in the on state, for example, if the terminal device is an air conditioner and is currently in the on state, the relevant status data includes one or more of the currently set mode of the air conditioner, the currently set temperature, the currently set wind speed and the like.
when detecting the network connection condition, the gateway device judges whether the network connection state or the network disconnection state is achieved through a heartbeat packet in the network, and if the heartbeat packet can be detected, the network connection state is achieved; if the heartbeat packet cannot be detected, setting a waiting time, if the heartbeat packet cannot be detected after the waiting time, confirming that the network is in a disconnected state, and at the moment, the gateway equipment tries to establish communication connection with the local host. The waiting time is the duration of the heartbeat packet, which is not detected, and preferably, the duration is set to one minute, and the user can also set the duration according to the requirement.
further, smart homes must be in a networked state at the time of initial installation. The cloud platform is connected with a mobile terminal, each terminal device is bound with a corresponding control instruction through application software carried by the mobile terminal, and the corresponding relation between each terminal device and the control instruction is uploaded to the cloud platform for storage. Meanwhile, in a networking state, the local host establishes long connection with the cloud platform, and regularly acquires the corresponding relation between each terminal device and the control instruction stored in the cloud platform according to a preset time interval, so that when the control instruction bound by the terminal device is changed through the mobile terminal, the local host can timely acquire the change information, and normal use of a user is not influenced under the condition of network disconnection. Preferably, the time interval is half an hour, and the user can set the time interval according to needs.
meanwhile, in order to ensure that the local host can control and query the terminal equipment to the maximum extent, debugging is needed to ensure that the local host and the gateway equipment are in the same network segment, and the local host can find the corresponding gateway equipment in a local area network formed by the local host, the router, the gateway equipment and each terminal equipment, so that the control on each terminal equipment is realized under the condition of network disconnection.
In a preferred embodiment of the present invention, in step S4, as shown in fig. 2, the process of establishing a communication connection between the gateway device and the local host specifically includes:
step A1, the gateway device switches the communication mode from TCP communication to UDP communication;
step A2, the gateway device sends a broadcast command in the communication mode of UDP communication to obtain the IP address of the local host;
Step A3, the gateway device switches the communication mode from UDP communication to TCP communication mode and establishes communication connection with the local host according to the IP address.
specifically, in this embodiment, since the network IP address is a leased type, the IP address changes after a period of time, and although the history IP address of the local host is stored in the gateway device, it cannot be determined that the history IP address currently corresponds to the local host, so that a correct connection cannot be established with the local host. Therefore, in this embodiment, the gateway device first switches the communication mode from TCP communication to UDP communication, and sends a broadcast command in the communication mode of UDP communication to acquire the current IP address of the local host, and then switches the communication mode from UDP communication to TCP communication, and establishes a communication connection with the local host according to the acquired current IP address of the local host. After the gateway device establishes communication connection with the local host, the current control mode of each terminal device in the local host can be seen on the application program carried by the mobile terminal.
in a preferred embodiment of the present invention, a first control list indicating a correspondence between each terminal device and a control instruction is pre-stored in the cloud platform;
as shown in fig. 3, the generation process of the first control list specifically includes:
step B1, a mobile terminal connected with the cloud platform binds corresponding control instructions to each terminal device and uploads the binding results to the cloud platform;
step B2, the cloud platform generates and stores a first control list according to the binding result;
the first control list comprises the corresponding relation between each terminal device and the control instruction.
in a preferred embodiment of the invention, the method further comprises a process of presetting a local control list, and long connection is kept between the local host and the cloud platform;
as shown in fig. 4, the process of presetting the local control list specifically includes:
Step C1, detecting the communication state between the local host and the cloud platform in real time:
if the communication status indicates that the long connection is normal, go to step C2;
if the communication status indicates that the long connection is broken, the local host continuously attempts to reestablish the long connection, and then returns to step C1;
and step C2, the local host acquires the first control list stored in the cloud platform and stores the first control list as a local control list.
specifically, in this embodiment, the local host has two connections, one connection is a long connection with the cloud platform, and the other connection is a connection with the gateway device in the network disconnection state. In a networking state, the local host acquires a first control list stored in the cloud platform in real time through long connection with the cloud platform; in the disconnected state, the local host continuously attempts to reestablish the long connection with the cloud platform.
in a preferred embodiment of the present invention, as shown in fig. 5, the process of updating the local control list further includes:
step D1, the cloud platform receives the change information of the corresponding relation between each terminal device and the control instruction uploaded by the mobile terminal, and updates the first control list according to the change information;
and D2, the local host regularly acquires a first control list stored in the cloud platform according to a preset time interval, and updates the local control list according to the first control list.
in the preferred embodiment of the present invention, the local host and the gateway device are in the same network segment.
a control system of a smart home, which applies any one of the above control methods of a smart home, as shown in fig. 6, the control system specifically includes:
A router 1 is arranged in a network, the router 1 is respectively connected with at least one gateway device 2 and a local host 3, and the gateway device 2 is connected with a plurality of terminal devices 4;
The gateway device 2 specifically includes:
The first detection module 21 is configured to detect a heartbeat packet in a network in real time, output a first detection result when the heartbeat packet is detected, and output a second detection result when the heartbeat packet is not detected;
The first control module 22 is connected to the first detection module 21, and configured to establish a communication connection with a cloud platform 5 connected to the router 1 according to the first detection result, receive a control instruction sent by the cloud platform 5 to control each terminal device 4, and receive an inquiry instruction sent by the cloud platform 5 to obtain real-time state information of each terminal device 4;
the timing module 23 is connected to the first detection module 21, and is configured to count the duration of the undetected heartbeat packet according to the second detection result, compare the duration with a preset duration threshold, and output a corresponding determination result when the duration is not less than the duration threshold;
and the second control module 24 is connected to the timing module 23, and configured to establish a communication connection with the local host 3 connected to the router 1 according to the determination result, receive a control instruction sent by the local host 3 to control each terminal device 4, and receive an inquiry instruction sent by the local host 3 to obtain real-time status information of each terminal device 4.
in a preferred embodiment of the present invention, the second control module 24 specifically includes:
A processing unit 241, configured to switch the communication mode from TCP communication to UDP communication according to the determination result;
An inquiry unit 242, connected to the processing unit 241, for sending a broadcast command in the communication mode of UDP communication to acquire the IP address of the local host 3;
a control unit 243, a connection inquiry unit 242, configured to switch the communication mode from the UDP communication to the TCP communication mode, and establish a communication connection with the local host 3 according to the IP address.
in a preferred embodiment of the present invention, the mobile terminal 6 is further included, connected to the cloud platform 5, and configured to bind the corresponding control instruction to each terminal device 4 and upload the binding result to the cloud platform 5.
In a preferred embodiment of the present invention, the local host 3 specifically includes:
A storage module 31, configured to store a local control list obtained in advance, where the local control list includes the terminal device 4 and a control instruction corresponding to the terminal device;
the second detection module 32 is configured to detect a communication state between the local host 3 and the cloud platform 5 in real time, output a corresponding third detection result when the communication state indicates that the long connection is normal, and output a corresponding fourth detection result when the communication state indicates that the long connection is disconnected;
and the first control module 33 is connected to the second detection module 32 and the storage module 31, and configured to periodically obtain, according to the third detection result and according to a preset time interval, a first control list pre-generated in the cloud platform 5, and update the local control list according to the first control list.
And a second control module 34, connected to the second detection module 32, for continuously attempting to reestablish the long connection according to the fourth detection result.
while the invention has been described with reference to a preferred embodiment, it will be understood by those skilled in the art that various changes in form and detail may be made therein without departing from the spirit and scope of the invention.

Claims (10)

1. the control method for the smart home is characterized by specifically comprising the following steps: setting a router in a network, wherein the router is respectively connected with at least one gateway device and a local host, and the gateway device is connected with a plurality of terminal devices;
The control method specifically comprises the following steps:
Step S1, the gateway device detects, in real time, the heartbeat packet in the network:
if the heartbeat packet is detected, turning to step S2;
if the heartbeat packet is not detected, turning to step S3;
step S2, the gateway device establishes a communication connection with a cloud platform connected to the router, receives a control instruction sent by the cloud platform to control each terminal device, receives an inquiry instruction sent by the cloud platform to obtain real-time status information of each terminal device, and then returns to step S1;
Step S3, the gateway device counts the duration of the heartbeat packet that is not detected, and compares the duration with a preset duration threshold:
If the duration is less than the duration threshold, it indicates that the gateway device is in a networking state, and then returns to the step S2;
if the duration is not less than the duration threshold, indicating that the gateway device is in a disconnected state, and then turning to step S4;
step S4, the gateway device establishes a communication connection with the local host connected to the router, receives a control command sent by the local host to control each of the terminal devices, receives a query command sent by the local host to obtain real-time status information of each of the terminal devices, and then returns to step S1.
2. the smart home control method according to claim 1, wherein in step S4, the process of establishing the communication connection between the gateway device and the local host specifically includes:
Step A1, the gateway device switches the communication mode from TCP communication to UDP communication;
step a2, the gateway device sending a broadcast command in the communication mode of the UDP communication to obtain the IP address of the local host;
step a3, the gateway device switches the communication mode from the UDP communication to the TCP communication mode, and establishes the communication connection with the local host according to the IP address.
3. The intelligent home control method according to claim 1, wherein a first control list indicating correspondence between each of the terminal devices and the control instruction is pre-stored in the cloud platform;
the generation process of the first control list specifically comprises the following steps:
step B1, a mobile terminal connected with the cloud platform binds the corresponding control instruction to each terminal device and uploads the binding result to the cloud platform;
step B2, the cloud platform generates and stores the first control list according to the binding result;
and the first control list comprises the corresponding relation between each terminal device and the control instruction.
4. The smart home control method according to claim 3, further comprising a process of presetting a local control list, wherein the local host maintains long connection with the cloud platform;
the process of presetting the local control list specifically includes:
step C1, the local host detects the communication state between the local host and the cloud platform in real time:
if the communication status indicates that the long connection is normal, go to step C2;
if the communication status indicates that the long connection is broken, the local host continuously attempts to reestablish the long connection, and then returns to the step C1;
Step C2, the local host acquires the first control list stored in the cloud platform and stores the first control list as the local control list.
5. the smart home control method according to claim 4, further comprising a process of updating the local control list, specifically comprising:
step D1, the cloud platform receives change information of the corresponding relation between each terminal device and the control instruction, which is uploaded by the mobile terminal, and updates the first control list according to the change information;
and D2, the local host regularly acquires the first control list stored in the cloud platform according to a preset time interval, and updates the local control list according to the first control list.
6. the smart home control method according to claim 1, wherein the local host and the gateway device are in the same network segment.
7. A control system of smart home, which is characterized in that the control method of smart home according to any one of claims 1 to 6 is applied, and the control system specifically comprises:
setting a router in a network, wherein the router is respectively connected with at least one gateway device and a local host, and the gateway device is connected with a plurality of terminal devices;
the gateway device specifically includes:
The first detection module is used for detecting the heartbeat packet in the network in real time, outputting a first detection result when the heartbeat packet is detected, and outputting a second detection result when the heartbeat packet is not detected;
The first control module is connected with the first detection module and used for establishing communication connection with a cloud platform connected with the router according to the first detection result, receiving a control instruction sent by the cloud platform to control each terminal device, and receiving an inquiry instruction sent by the cloud platform to acquire real-time state information of each terminal device;
the timing module is connected with the first detection module and used for counting the duration of the heartbeat packet which is not detected according to the second detection result, comparing the duration with a preset duration threshold and outputting a corresponding judgment result when the duration is not less than the duration threshold;
And the second control module is connected with the timing module and used for establishing communication connection with the local host connected with the router according to the judgment result, receiving a control instruction sent by the local host to control each terminal device, and receiving a query instruction sent by the local host to acquire real-time state information of each terminal device.
8. the smart home control system according to claim 7, wherein the second control module specifically comprises:
The processing unit is used for switching the communication mode from TCP communication to UDP communication according to the judgment result;
The query unit is connected with the processing unit and used for sending a broadcast command in a communication mode of the UDP communication to acquire the IP address of the local host;
And the control unit is connected with the query unit and used for switching the communication mode from the UDP communication to the TCP communication mode and establishing the communication connection with the local host according to the IP address.
9. the intelligent home control system according to claim 7, further comprising a mobile terminal connected to the cloud platform and configured to bind each of the terminal devices with a corresponding control instruction and upload a binding result to the cloud platform.
10. the smart home control method according to claim 7, wherein the local host specifically comprises:
the storage module is used for storing a local control list acquired in advance, and the local control list comprises the terminal equipment and the control instruction corresponding to the terminal equipment;
the second detection module is used for detecting the communication state between the local host and the cloud platform in real time, outputting a corresponding third detection result when the communication state indicates that the long connection is normal, and outputting a corresponding fourth detection result when the communication state indicates that the long connection is disconnected;
And the first control module is respectively connected with the second detection module and the storage module and is used for regularly acquiring a first control list generated in the cloud platform in advance according to the third detection result and a preset time interval and updating the local control list according to the first control list.
and the second control module is connected with the second detection module and used for continuously trying to reestablish the long connection according to the fourth detection result.
CN201910810482.XA 2019-08-29 2019-08-29 Control method and system for smart home Pending CN110557448A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910810482.XA CN110557448A (en) 2019-08-29 2019-08-29 Control method and system for smart home

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910810482.XA CN110557448A (en) 2019-08-29 2019-08-29 Control method and system for smart home

Publications (1)

Publication Number Publication Date
CN110557448A true CN110557448A (en) 2019-12-10

Family

ID=68738404

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910810482.XA Pending CN110557448A (en) 2019-08-29 2019-08-29 Control method and system for smart home

Country Status (1)

Country Link
CN (1) CN110557448A (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111142394A (en) * 2019-12-25 2020-05-12 珠海格力电器股份有限公司 Control method, device and equipment of cooking equipment and computer readable medium
CN112003753A (en) * 2020-08-25 2020-11-27 四川长虹电器股份有限公司 Expected value judgment, acquisition, transmission and monitoring system and method based on configurable gateway
CN112165413A (en) * 2020-09-27 2021-01-01 海尔优家智能科技(北京)有限公司 Equipment state reporting method and device and electronic device
CN112666877A (en) * 2021-02-01 2021-04-16 亚特智物联技术(广东)有限公司 Control system of Internet of things
CN112689252A (en) * 2020-12-04 2021-04-20 广东亚太天能科技股份有限公司 Intelligent household Internet of things transmission system and method based on physical layer
WO2021218317A1 (en) * 2020-04-29 2021-11-04 京东方科技集团股份有限公司 Network reentry method for mobile terminal after network disconnection, and related device
CN113645602A (en) * 2021-08-19 2021-11-12 深圳创维数字技术有限公司 Method, system, communication terminal and readable storage medium for decentralized management
CN113691401A (en) * 2021-08-20 2021-11-23 珠海格力电器股份有限公司 User equipment, control method thereof, data transmission method and Internet of things cloud platform
CN113965610A (en) * 2021-10-23 2022-01-21 福建百悦信息科技有限公司 Remote ammeter control method
CN114500669A (en) * 2021-12-31 2022-05-13 珠海派诺科技股份有限公司 Real-time communication method and system based on Internet of things, storage medium and electronic equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105119946A (en) * 2015-06-17 2015-12-02 深圳市美贝壳科技有限公司 Intelligent household electrical appliance control device and method capable of automatically switching network
CN106713090A (en) * 2017-01-17 2017-05-24 华东交通大学 Smart home system
CN106789468A (en) * 2016-12-22 2017-05-31 Tcl集团股份有限公司 A kind of appliances equipment control method and system based on intelligent terminal
CN107483301A (en) * 2017-08-28 2017-12-15 四川长虹电器股份有限公司 The control method of intelligent domestic system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105119946A (en) * 2015-06-17 2015-12-02 深圳市美贝壳科技有限公司 Intelligent household electrical appliance control device and method capable of automatically switching network
CN106789468A (en) * 2016-12-22 2017-05-31 Tcl集团股份有限公司 A kind of appliances equipment control method and system based on intelligent terminal
CN106713090A (en) * 2017-01-17 2017-05-24 华东交通大学 Smart home system
CN107483301A (en) * 2017-08-28 2017-12-15 四川长虹电器股份有限公司 The control method of intelligent domestic system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
李森: "基于云平台的物联网远程控制技术研究", 《中国优秀硕士学位论文全文数据库信息科技辑》 *

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111142394B (en) * 2019-12-25 2021-12-07 珠海格力电器股份有限公司 Control method, device and equipment of cooking equipment and computer readable medium
CN111142394A (en) * 2019-12-25 2020-05-12 珠海格力电器股份有限公司 Control method, device and equipment of cooking equipment and computer readable medium
WO2021218317A1 (en) * 2020-04-29 2021-11-04 京东方科技集团股份有限公司 Network reentry method for mobile terminal after network disconnection, and related device
CN112003753A (en) * 2020-08-25 2020-11-27 四川长虹电器股份有限公司 Expected value judgment, acquisition, transmission and monitoring system and method based on configurable gateway
CN112165413A (en) * 2020-09-27 2021-01-01 海尔优家智能科技(北京)有限公司 Equipment state reporting method and device and electronic device
CN112689252A (en) * 2020-12-04 2021-04-20 广东亚太天能科技股份有限公司 Intelligent household Internet of things transmission system and method based on physical layer
CN112689252B (en) * 2020-12-04 2023-10-27 广东亚太天能科技股份有限公司 Physical layer-based intelligent home Internet of things transmission system and method
CN112666877A (en) * 2021-02-01 2021-04-16 亚特智物联技术(广东)有限公司 Control system of Internet of things
CN113645602A (en) * 2021-08-19 2021-11-12 深圳创维数字技术有限公司 Method, system, communication terminal and readable storage medium for decentralized management
CN113645602B (en) * 2021-08-19 2023-09-19 深圳创维数字技术有限公司 Distributed management method, system, communication terminal and readable storage medium
CN113691401A (en) * 2021-08-20 2021-11-23 珠海格力电器股份有限公司 User equipment, control method thereof, data transmission method and Internet of things cloud platform
CN113965610A (en) * 2021-10-23 2022-01-21 福建百悦信息科技有限公司 Remote ammeter control method
CN114500669A (en) * 2021-12-31 2022-05-13 珠海派诺科技股份有限公司 Real-time communication method and system based on Internet of things, storage medium and electronic equipment

Similar Documents

Publication Publication Date Title
CN110557448A (en) Control method and system for smart home
WO2019205134A1 (en) Smart home voice control method, apparatus, device and system
CN106789305B (en) Intelligent gateway for remotely adjusting parameters and control method
CN108064442B (en) Intelligent equipment control method, control device and control system
CN110460977B (en) Intelligent lighting equipment network distribution method based on Bluetooth MESH
CN105652675B (en) A kind of control method of smart home device, device, terminal and system
CN105245596B (en) A kind of long-range control method and server
US20140118120A1 (en) Smart gateway, smart home system and smart controlling method thereof
CN110519306B (en) Equipment access control method and device of Internet of things
CN109547306A (en) A kind of smart home device management method, system, intelligent gateway and server
CN105573135A (en) Control method and apparatus for intelligent household electrical appliances
CN108431701B (en) Control method, control panel and control system of intelligent household equipment
CN105159121B (en) Household electrical appliance and its on-off control method and system and smart machine
CN104991539A (en) Smart home automated system
CN111010324A (en) Household appliance ad hoc network method and system based on BLE MESH network protocol
CN106899603A (en) A kind of smart machine monitoring method and device
CN109753034A (en) A kind of control method, device, electronic equipment and storage medium
CN107689903A (en) Intelligent home equipment control method, system, storage medium and computer equipment
CN109100950A (en) A kind of control method and smart home system of smart home device
US11095471B2 (en) Home-automation system and method for constituting the topology of a home-automation system
CN104880955A (en) Method for controlling intelligent household device, and intelligent household control device
CN112596406A (en) Control method and device of intelligent equipment, control panel and storage medium
CN110868707A (en) BLE MESH-based intelligent device network distribution method
CN108111379A (en) A kind of method and apparatus for controlling smart home device
CN106302078A (en) Group network system

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20191210