CN114553626B - Equipment state query method, query device, electronic equipment and storage medium - Google Patents

Equipment state query method, query device, electronic equipment and storage medium Download PDF

Info

Publication number
CN114553626B
CN114553626B CN202210301965.9A CN202210301965A CN114553626B CN 114553626 B CN114553626 B CN 114553626B CN 202210301965 A CN202210301965 A CN 202210301965A CN 114553626 B CN114553626 B CN 114553626B
Authority
CN
China
Prior art keywords
target
configuration file
state
gateway
intelligent
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
CN202210301965.9A
Other languages
Chinese (zh)
Other versions
CN114553626A (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.)
Shenzhen Oribo Technology Co Ltd
Original Assignee
Shenzhen Oribo Technology 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 Shenzhen Oribo Technology Co Ltd filed Critical Shenzhen Oribo Technology Co Ltd
Priority to CN202210301965.9A priority Critical patent/CN114553626B/en
Publication of CN114553626A publication Critical patent/CN114553626A/en
Application granted granted Critical
Publication of CN114553626B publication Critical patent/CN114553626B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/2803Home automation networks
    • H04L12/2807Exchanging configuration information on appliance services in a home automation network
    • GPHYSICS
    • G08SIGNALLING
    • G08CTRANSMISSION SYSTEMS FOR MEASURED VALUES, CONTROL OR SIMILAR SIGNALS
    • G08C17/00Arrangements for transmitting signals characterised by the use of a wireless electrical link
    • G08C17/02Arrangements for transmitting signals characterised by the use of a wireless electrical link using a radio link
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • 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/24Negotiation of communication capabilities
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W24/00Supervisory, monitoring or testing arrangements
    • H04W24/04Arrangements for maintaining operational condition
    • 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/284Home automation networks characterised by the type of medium used
    • H04L2012/2841Wireless
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/02Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]

Abstract

The application discloses a device state query method, a query device, an electronic device and a storage medium, wherein the device state query method is applied to a wireless module, the wireless module is connected with a gateway, the wireless module is connected with at least one intelligent device, and the device state query method comprises the steps of obtaining a state parameter query instruction aiming at a target intelligent device; determining a target configuration file corresponding to target intelligent equipment based on a state parameter query instruction, wherein each intelligent equipment is preconfigured with a corresponding configuration file; polling the target intelligent device based on the target configuration file to obtain the current state parameter of the target intelligent device; and when the state of the target intelligent device is determined to be changed according to the current state parameter, the current state parameter is sent to the gateway. The method realizes that the gateway establishes communication connection with different intelligent devices based on a single wireless module, does not need to configure a plurality of wireless modules in the intelligent home system, and reduces the installation cost of the intelligent home system.

Description

Equipment state query method, query device, electronic equipment and storage medium
Technical Field
The application relates to the technical field of smart home, in particular to a device state query method, a query device, electronic equipment and a storage medium.
Background
With the rapid development of mobile intelligent terminals, household equipment is more and more intelligent. The intelligent home system takes a home space as a platform, integrates equipment related to home life by utilizing comprehensive wiring technology, network communication technology, security technology, automatic control technology, audio and video technology and the like, constructs an efficient management system for home facilities and family schedule matters, improves the safety, convenience, comfort and artistry of home equipment, and realizes environment-friendly and energy-saving living environment.
In the existing intelligent home system, intelligent equipment is connected to a gateway through a corresponding communication protocol module. However, different communication protocols of communication between different intelligent devices and the gateway are different, when the gateway communicates with different intelligent devices, communication connection needs to be established between the gateway and the corresponding intelligent devices through different communication protocol modules, so that a plurality of communication protocol modules need to be configured when the intelligent home system is installed, and the installation cost of the intelligent home system is high.
Disclosure of Invention
In view of the above problems, the application provides a device state query method, a query device, an electronic device and a storage medium, which can realize that a gateway establishes communication connection with different intelligent devices based on a single wireless module, a plurality of wireless modules are not required to be configured in an intelligent home system, and the installation cost of the intelligent home system is reduced.
In a first aspect, an embodiment of the present application provides a device status query method, applied to a wireless module, where the wireless module is connected with a gateway, and the wireless module is connected with at least one intelligent device, the device status query method includes: acquiring a state parameter query instruction aiming at target intelligent equipment; determining a target configuration file corresponding to target intelligent equipment based on a state parameter query instruction, wherein each intelligent equipment is preconfigured with a corresponding configuration file; polling the target intelligent device based on the target configuration file to obtain the current state parameter of the target intelligent device; and when the state of the target intelligent device is determined to be changed according to the current state parameter, the current state parameter is sent to the gateway.
In a second aspect, an embodiment of the present application provides a device status query apparatus, which is applied to a wireless module, where the wireless module is connected with a gateway, and the wireless module is connected with at least one intelligent device, and the device status query apparatus includes a query instruction acquisition module, a configuration file determination module, a polling module, and a sending module. The query instruction acquisition module is used for acquiring a state parameter query instruction aiming at the target intelligent equipment; the configuration file determining module is used for determining a target configuration file corresponding to the target intelligent equipment based on the state parameter query instruction, wherein each intelligent equipment is pre-configured with the corresponding configuration file; the polling module is used for polling the target intelligent equipment based on the target configuration file so as to obtain the current state parameters of the target intelligent equipment; and the sending module is used for sending the current state parameter to the gateway when the state of the target intelligent device is determined to change according to the current state parameter.
In a third aspect, embodiments of the present application provide an electronic device including a memory; one or more processors coupled to the memory; one or more applications, wherein the one or more applications are stored in memory and configured to be executed by the one or more processors, the one or more applications configured to perform the device state query method as provided in the first aspect above.
In a fourth aspect, embodiments of the present application provide a computer readable storage medium having program code stored therein, the program code being executable by a processor to perform the device state query method as provided in the first aspect above.
The scheme provided by the application is applied to the wireless module, the wireless module is connected with the gateway, the wireless module is connected with at least one intelligent device, the wireless module obtains a state parameter query instruction aiming at the target intelligent device and determines a target configuration file corresponding to the target intelligent device based on the state parameter query instruction, wherein each intelligent device is preconfigured with the corresponding configuration file and polls the target intelligent device based on the target configuration file so as to obtain the current state parameter of the target intelligent device, when the state of the target intelligent device is determined to change according to the current state parameter, the current state parameter is sent to the gateway, the gateway is connected with different intelligent devices in a communication mode based on a single wireless module, a plurality of wireless modules are not required to be configured in the intelligent home system, and the installation cost of the intelligent home system is reduced.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the description of the embodiments will be briefly introduced below, it being obvious that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 shows a schematic view of a scenario of a device status query system provided in an embodiment of the present application.
Fig. 2 shows a timing diagram of a device status query method according to an embodiment of the present application.
Fig. 3 is a schematic flow chart of a device status query method according to an embodiment of the present application.
Fig. 4 is a schematic flow chart of another method for querying a device state according to an embodiment of the present application.
Fig. 5 shows a further flowchart of a device status query method according to an embodiment of the present application.
Fig. 6 shows a block diagram of a device status query apparatus according to an embodiment of the present application.
Fig. 7 shows a functional block diagram of an electronic device according to an embodiment of the present application.
Fig. 8 illustrates a computer readable storage medium provided by an embodiment of the present application for storing or carrying program code for implementing a device state query method provided according to an embodiment of the present application.
Detailed Description
For the purposes of making the objects, technical solutions and advantages of the embodiments of the present application more clear, the technical solutions of the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is apparent that the described embodiments are some embodiments of the present application, but not all embodiments. The components of the embodiments of the present application, which are generally described and illustrated in the figures herein, may be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the present application, as provided in the accompanying drawings, is not intended to limit the scope of the application, as claimed, but is merely representative of selected embodiments of the application. All other embodiments, which can be made by one of ordinary skill in the art without undue burden from the present disclosure, are within the scope of the present disclosure.
It should be noted that: like reference numerals and letters denote like items in the following figures, and thus once an item is defined in one figure, no further definition or explanation thereof is necessary in the following figures.
In the description of the present application, it should be noted that the terms "first," "second," "third," and the like are used merely to distinguish between descriptions and are not to be construed as indicating or implying relative importance.
With the rapid development of mobile intelligent terminals, household equipment is more and more intelligent. The intelligent home system takes a home space as a platform, integrates equipment related to home life by utilizing comprehensive wiring technology, network communication technology, security technology, automatic control technology, audio and video technology and the like, constructs an efficient management system for home facilities and family schedule matters, improves the safety, convenience, comfort and artistry of home equipment, and realizes environment-friendly and energy-saving living environment.
In the existing intelligent home system, intelligent equipment is connected to a gateway through a corresponding communication protocol module. However, different communication protocols of communication between different intelligent devices and the gateway are different, when the gateway communicates with different intelligent devices, communication connection needs to be established between the gateway and the corresponding intelligent devices through different communication protocol modules, so that a plurality of communication protocol modules need to be configured when the intelligent home system is installed, and the installation cost of the intelligent home system is high.
Aiming at the problems, the inventor researches and puts forward the equipment state query method, the query device, the electronic equipment and the storage medium provided by the embodiment of the application for a long time, so that the gateway establishes communication connection with different intelligent equipment based on a single wireless module, a plurality of wireless modules are not required to be configured in the intelligent home system, and the installation cost of the intelligent home system is reduced.
Referring to fig. 1, an application scenario diagram of a device status query system provided in an embodiment of the present application includes a wireless module 100, a gateway 200, and an intelligent device 300, where the gateway 200 and the intelligent device 300 may be communicatively connected through the wireless module 100, and the gateway 200 and the intelligent device 300 may perform data interaction through the wireless module 100. The gateway 200 may send a status query instruction to the intelligent device 300 through the wireless module 100, and receive status parameters returned by the intelligent device 300 through the wireless module 100, thereby completing status query of the intelligent device 300. The state parameter may include at least any one of an operating voltage, an operating current, a consumed power, a cooling temperature, a heating temperature, brightness, volume, and the like.
The wireless module 100 may be a ZigBee (ZigBee) module, a bluetooth Low energy (Bluetooth Low Energy, BLE) module, a wireless fidelity (Wireless Fidelity, wi-Fi) module, a home internet of things (internet of things) protocol (Thread) module, a Long Range Radio (LoRa) module, a Low Power Wide Area Network (LPWAN) module, an infrared module, a narrowband internet of things (Narrow Band Internet of Things, NB-IoT) module, and so on. The type of the wireless module 100 is not limited herein, and may be specifically set according to actual requirements.
The wireless module 100 may establish a corresponding wireless communication connection with the gateway 200 through a wireless network, where the wireless network corresponds to a type of wireless module, for example, the wireless network may be a ZigBee network, a BLE network, a Wi-Fi network, a Thread network, a LoRa network, an LPWAN network, an infrared communication network, or an NB-IoT network.
The wireless module 100 may establish a serial communication connection with the smart device 300 through a serial bus, for example, the serial bus may be 485 bus, 232 bus, 422 bus, or the like.
Gateway 200 may be a lan/host gateway device, lan/lan gateway device, or internet/lan gateway device, etc.
The intelligent device 300 can be one or more, and the intelligent device 300 can include intelligent lighting equipment, intelligent air conditioner, intelligent door lock, intelligent television, intelligent audio amplifier, intelligent mirror, intelligent robot of sweeping the floor, intelligent clothes hanger, intelligent (window) curtain, intelligent camera, intelligent temperature and humidity detector, intelligent carbon monoxide alarm, door and window sensor, human body sensor, intelligent water logging detector, intelligent alarm device, smart socket, intelligent row of inserting etc..
In an application scenario, please refer to fig. 2, fig. 2 is a timing diagram of an apparatus status query method according to an embodiment of the present application. The method flow may include:
S1: the wireless module 100 sends a networking request to the gateway 200.
Wherein the networking request may be used to instruct gateway 200 to establish a wireless communication connection with wireless module 100 over a corresponding wireless network.
S2: the gateway 200 establishes a wireless communication connection with the wireless module 100 through a corresponding wireless network, and transmits a configuration file corresponding to the intelligent device 300 to the wireless module 100.
The configuration file may include polling rule information, communication protocol information, etc. between the wireless module 100 and the smart device 300. The polling rule information may include device address information, polling period information, register address information, function code information, etc. corresponding to the smart device 300; the communication protocol information may include data format information, data size information, baud rate information, etc. when the wireless module 100 communicates with the smart device 300.
S3: the wireless module 100 receives and saves the configuration file sent by the gateway 200.
S4: the gateway 200 sends a control instruction corresponding to the intelligent device 300 to the wireless module 100.
S5: the wireless module 100 transmits a control instruction to the smart device 300 based on the configuration file.
S6: the smart device 300 receives and responds to the received control command to start the operation.
S7: the wireless module 100 sends a polling command to the smart device 300 based on the configuration file.
S8: the smart device 300 receives and responds to the polling instruction by sending current status parameters of the smart device 300 to the wireless module 100.
S9: the wireless module 100 receives the current status parameters sent by the smart device 300.
S10: the wireless module 100 determines whether the state of the smart device 300 is changed according to the current state parameter.
S11: the wireless module 100 transmits the current state parameter to the gateway 200 upon determining that the state of the smart device 300 has changed.
S12: gateway 200 receives the current state parameters sent by wireless module 100.
The following will describe specific examples.
Referring to fig. 3, a flowchart of a device status query method according to an embodiment of the present application is shown. In a specific embodiment, the device state query method may be applied to the wireless module 100 in the device state query system shown in fig. 1, and the flow shown in fig. 3 will be described in detail below by taking the wireless module 100 as an example, and the device state query method may include the following steps S110 to S140.
Step S110: and acquiring a state parameter query instruction aiming at the target intelligent equipment.
In the embodiment of the application, one or more intelligent devices can be used, after the intelligent devices are in communication connection with the gateway through the wireless module, and when the intelligent devices are in a working state, in order to realize state query of the target intelligent devices, the wireless module can acquire a state parameter query instruction aiming at the target intelligent devices.
In some embodiments, when the state of the target intelligent device changes, the target intelligent device may send corresponding first prompt information to the wireless module, and the wireless module receives the first prompt information sent by the target intelligent device, and based on the first prompt information, may generate a state parameter query instruction for the target intelligent device. The first prompt information is only information triggering the wireless module to generate a state parameter query instruction, and does not contain state parameter information of the target intelligent equipment. According to the state change of the target intelligent device, the wireless module is actively prompted to inquire the state parameters of the target intelligent device, so that the situation that the state parameters of the target intelligent device are not inquired and processed in time when the state change of the target intelligent device is a fault state is avoided, the target intelligent device is damaged, and the operation safety of the target intelligent device is improved.
In some embodiments, when the state of the target intelligent device changes, the target intelligent device may send a corresponding second prompt message to the wireless module, the wireless module receives and responds to the second prompt message, and may send the second prompt message to the gateway, the gateway receives and responds to the second prompt message, and may generate a state parameter query instruction for the target intelligent device, and send the state parameter query instruction to the wireless module, and the wireless module receives the state parameter query instruction returned by the gateway. The second prompt information is only information triggering the gateway to generate a state parameter query instruction, and does not contain state parameter information of the target intelligent device. According to the state change of the target intelligent device, the gateway is actively prompted to inquire the state parameters of the target intelligent device, so that the situation that the state parameters of the target intelligent device are not inquired and processed in time when the state change of the target intelligent device is a fault state is avoided, the target intelligent device is damaged, and the operation safety of the target intelligent device is improved.
In some embodiments, the device status query system may further include a terminal device that may be communicatively coupled to the gateway via a wireless network. When receiving a query request corresponding to a target intelligent device input by a user, the terminal device can generate a state parameter query instruction aiming at the target intelligent device, and send the state parameter query instruction to the gateway through the wireless network, the gateway receives and responds to the state parameter query instruction, and sends the state parameter query instruction to the wireless module, and the wireless module receives the state parameter query instruction sent by the gateway.
Step S120: and determining a target configuration file corresponding to the target intelligent equipment based on the state parameter query instruction.
In this embodiment of the present application, each smart device is preconfigured with a corresponding configuration file, a configuration file table is prestored in the wireless module, and the configuration file table may include a plurality of smart device information and a configuration file corresponding to each smart device information, and the configuration file table may be used to characterize a correspondence between each smart device information and the configuration file.
After acquiring the state parameter query instruction for the target intelligent device, the wireless module can search the configuration file table according to the target intelligent device information corresponding to the state parameter query instruction to obtain a target configuration file corresponding to the target intelligent device.
For example, the correspondence between the intelligent device information and the configuration file may be as shown in table 1, the configuration files corresponding to different intelligent device information are shown in table 1, and the target configuration file corresponding to the target intelligent device may be obtained according to the pair of correspondence.
TABLE 1
It should be noted that, the correspondence between the information of the intelligent device and the configuration file is not limited to those shown in table 1, and may be specifically set according to actual requirements.
Step S130: and polling the target intelligent device based on the target configuration file to obtain the current state parameters of the target intelligent device.
In the embodiment of the application, after determining the target configuration file corresponding to the target intelligent device based on the state parameter query instruction, the wireless module may generate the polling instruction corresponding to the target intelligent device based on the target configuration file, send the polling instruction to the target intelligent device based on the target configuration file, receive and respond to the polling instruction by the target intelligent device, send the current state parameter of the target intelligent device to the wireless module, and receive the current state parameter returned by the target intelligent device by the wireless module.
In some embodiments, after determining the target configuration file corresponding to the target intelligent device based on the state parameter query instruction, the wireless module may determine a corresponding polling rule and a communication protocol based on the target configuration file, generate a polling instruction corresponding to the target intelligent device, establish a communication connection with the target intelligent device based on the communication protocol, send the polling instruction to the target intelligent device according to the polling rule, receive and respond to the polling instruction by the target intelligent device, send the current state parameter to the wireless module, and receive the current state parameter returned by the target intelligent device by the wireless module.
For example, the polling rule may be a rule including polling period information and device address information, and the communication protocol may be a protocol including data format information, data size information, and baud rate information. The wireless module can establish communication connection with the target intelligent device based on the data format information, the data size information and the baud rate information, and periodically send a polling command to the target intelligent device corresponding to the device address according to a polling period.
Step S140: and when the state of the target intelligent device is determined to be changed according to the current state parameter, the current state parameter is sent to the gateway.
In the embodiment of the application, after the wireless module polls the target intelligent device based on the target configuration file to obtain the current state parameter of the target intelligent device, when the state of the target intelligent device is determined to change according to the current state parameter, the current state parameter can be sent to the gateway, so that the gateway establishes communication connection with different intelligent devices based on a single wireless module, a plurality of wireless modules are not required to be configured in the intelligent home system, and the installation cost of the intelligent home system is reduced.
The scheme provided by the application is applied to the wireless module, the wireless module is connected with the gateway, the wireless module is connected with at least one intelligent device, the wireless module obtains a state parameter query instruction aiming at the target intelligent device and determines a target configuration file corresponding to the target intelligent device based on the state parameter query instruction, wherein each intelligent device is preconfigured with the corresponding configuration file and polls the target intelligent device based on the target configuration file so as to obtain the current state parameter of the target intelligent device, when the state of the target intelligent device is determined to change according to the current state parameter, the current state parameter is sent to the gateway, the gateway is connected with different intelligent devices in a communication mode based on a single wireless module, a plurality of wireless modules are not required to be configured in the intelligent home system, and the installation cost of the intelligent home system is reduced.
Referring to fig. 4, a flowchart of a device status query method according to another embodiment of the present application is shown. In a specific embodiment, the device state query method may be applied to the wireless module 100 in the device state query system shown in fig. 1, and the flow shown in fig. 4 will be described in detail below by taking the wireless module 100 as an example, and the device state query method may include the following steps S210 to S260.
Step S210: and acquiring a state parameter query instruction aiming at the target intelligent equipment.
In this embodiment, step S210 may refer to the content of the corresponding steps in the foregoing embodiments, which is not described herein.
Step S220: and receiving the configuration file of each intelligent device sent by the gateway.
In this embodiment, after acquiring the state parameter query instruction for the target intelligent device, the wireless module may generate a configuration file acquisition instruction and send the configuration file acquisition instruction to the gateway through the wireless network, where the gateway receives and responds to the configuration file acquisition instruction and may send the configuration file of each intelligent device configured in advance to the wireless module through the wireless network, where the wireless module receives the configuration file of each intelligent device sent by the gateway, so that the gateway may establish communication connection with a plurality of intelligent devices based on a single wireless module.
Step S230: and uniformly storing the configuration file of each intelligent device through the universal firmware.
In this embodiment, the wireless module is configured with a general-purpose firmware, which may be used to store configuration files corresponding to a plurality of intelligent devices. After the wireless module receives the configuration file of each intelligent device sent by the gateway, the configuration file of each intelligent device can be uniformly stored through the universal firmware, so that the configuration files of a plurality of intelligent devices are stored through the universal firmware, one firmware for storing the corresponding configuration file is not required to be developed for each intelligent device, and only the universal firmware is required to be maintained during equipment maintenance, so that low equipment maintenance efficiency caused by the need of maintaining the plurality of firmware is avoided, and the maintenance efficiency of equipment maintenance is improved.
In some embodiments, after the configuration file of each intelligent device is uniformly stored by the universal firmware, if a new configuration file of at least one intelligent device sent by the gateway is received, the configuration file of the intelligent device stored in the universal firmware can be replaced by the new configuration file of the intelligent device, so that the configuration file of the intelligent device is automatically updated, the configuration file of the intelligent device is not required to be manually updated by a user, and the user experience is improved.
Step S240: and determining a target configuration file corresponding to the target intelligent equipment based on the state parameter query instruction.
Step S250: and polling the target intelligent device based on the target configuration file to obtain the current state parameters of the target intelligent device.
Step S260: and when the state of the target intelligent device is determined to be changed according to the current state parameter, the current state parameter is sent to the gateway.
In this embodiment, the steps S240, S250 and S260 may refer to the content of the corresponding steps in the foregoing embodiments, which is not described herein.
The scheme provided by the embodiment is applied to the wireless module, the wireless module is connected with the gateway, the wireless module is connected with at least one intelligent device, the wireless module is used for acquiring a state parameter query instruction for the target intelligent device, receiving configuration files of each intelligent device sent by the gateway, uniformly storing the configuration files of each intelligent device through the universal firmware, determining a target configuration file corresponding to the target intelligent device based on the state parameter query instruction, polling the target intelligent device based on the target configuration files to obtain the current state parameters of the target intelligent device, and sending the current state parameters to the gateway when the state of the target intelligent device is determined to change according to the current state parameters, so that the configuration files of a plurality of intelligent devices are stored through the universal firmware, the firmware is not required to be developed for storing the corresponding configuration files, the equipment maintenance efficiency low caused by the need of maintaining the plurality of firmware is avoided, and the equipment maintenance efficiency is improved.
Referring to fig. 5, a flowchart of a device status query method according to still another embodiment of the present application is shown. In a specific embodiment, the device state query method may be applied to the wireless module 100 in the device state query system shown in fig. 1, and the flow shown in fig. 5 will be described in detail below by taking the wireless module 100 as an example, and the device state query method may include the following steps S310 to S370.
Step S310: and acquiring a state parameter query instruction aiming at the target intelligent equipment.
Step S320: and determining a target configuration file corresponding to the target intelligent equipment based on the state parameter query instruction.
Step S330: and polling the target intelligent device based on the target configuration file to obtain the current state parameters of the target intelligent device.
In this embodiment, the steps S310, S320 and S330 may refer to the content of the corresponding steps in the foregoing embodiments, which is not described herein.
Step S340: and acquiring initial state parameters of the target intelligent equipment.
In this embodiment, after polling the target intelligent device based on the target configuration file, the wireless module may obtain the initial state parameter of the target intelligent device after obtaining the current state parameter of the target intelligent device, so as to determine whether the state of the target intelligent device changes according to the initial state parameter and the current state parameter.
In some embodiments, the device status query system may further include a server, which may be communicatively connected to the gateway through a wireless network, in which initial status parameters of the target smart device are pre-stored. The wireless module can send a first acquisition request corresponding to the target intelligent device to the gateway through the wireless network, the gateway receives and responds to the first acquisition request, the first acquisition request is forwarded to the server through the wireless network, the server receives and responds to the first acquisition request, initial state parameters of the target intelligent device are sent to the gateway through the wireless network, the gateway receives and responds to the initial state parameters, the initial state parameters are sent to the wireless module through the wireless network, and the wireless module receives the initial state parameters returned by the gateway.
In some embodiments, the initial state parameters of the target intelligent device are stored in the local memory of the gateway in advance, the wireless module can send a second acquisition request corresponding to the target intelligent device to the gateway through the wireless network, the gateway receives and responds to the second acquisition request, the initial state parameters of the target intelligent device are read from the local memory, the initial state parameters are sent to the wireless module through the wireless network, and the wireless module receives the initial state parameters returned by the gateway.
In some embodiments, the general firmware of the wireless module stores the initial state parameters of the target smart device in advance, and the wireless module may read the initial state parameters of the target smart device from the general firmware.
Step S350: a parameter difference between the current state parameter and the initial state parameter is calculated.
In this embodiment, after the wireless module obtains the initial state parameter of the target intelligent device, the wireless module may calculate a parameter difference between the current state parameter and the initial state parameter, so as to determine whether the state of the target intelligent device changes according to the parameter difference.
Step S360: and determining whether the state of the target intelligent device changes according to the parameter difference value and the difference value threshold value.
In this embodiment, after calculating the parameter difference between the current state parameter and the initial state parameter, the wireless module may determine whether the state of the target intelligent device changes according to the parameter difference and the difference threshold.
When the parameter difference value is larger than the difference value threshold value, determining that the state of the target intelligent equipment is changed; and when the parameter difference value is smaller than or equal to the difference value threshold value, determining that the state of the target intelligent equipment is unchanged.
Step S370: and when the state of the target intelligent device is determined to be changed according to the current state parameter, the current state parameter is sent to the gateway.
In this embodiment, step S370 may refer to the content of the corresponding steps in the foregoing embodiments, which is not described herein.
The scheme provided by the embodiment is applied to the wireless module, the wireless module is connected with the gateway, the wireless module is connected with at least one intelligent device, the wireless module obtains a state parameter query instruction for the target intelligent device, determines a target configuration file corresponding to the target intelligent device based on the state parameter query instruction, polls the target intelligent device based on the target configuration file to obtain the current state parameter of the target intelligent device, obtains the initial state parameter of the target intelligent device, calculates a parameter difference value between the current state parameter and the initial state parameter, determines whether the state of the target intelligent device changes according to the parameter difference value and the difference value threshold, and sends the current state parameter to the gateway when the state of the target intelligent device is determined to change according to the current state parameter, so that the gateway establishes communication connection with different intelligent devices based on a single wireless module without configuring a plurality of wireless modules in an intelligent home system, and the installation cost of the intelligent home system is reduced.
Referring to fig. 6, an apparatus 400 for querying a device status is shown, where the apparatus 400 for querying a device status may be applied to a wireless module 100 in a device status querying system shown in fig. 1, the wireless module 100 is connected to a gateway 200, and the wireless module 100 is connected to at least one smart device 300. The device state query apparatus 400 shown in fig. 6 will be described in detail with reference to the wireless module 100, and the device state query apparatus 400 may include a query instruction acquisition module 410, a configuration file determination module 420, a polling module 430, and a transmission module 440.
The query instruction acquisition module 410 may be configured to acquire a state parameter query instruction for a target smart device; the profile determination module 420 may be configured to determine, based on the status parameter query instruction, a target profile corresponding to a target smart device, where each smart device is preconfigured with a corresponding profile; the polling module 430 may be configured to poll the target smart device based on the target profile to obtain current state parameters of the target smart device; the sending module 440 may be configured to send the current state parameter to the gateway when it is determined that the state of the target smart device changes according to the current state parameter.
In some embodiments, the query instruction acquisition module 410 may include a first receiving unit and a first generating unit.
The first receiving unit can be used for receiving first prompt information sent by the target intelligent equipment, and the first prompt information is used for representing the state change of the target intelligent equipment; the first generating unit may be configured to generate a state parameter query instruction for the target smart device based on the first prompt information.
In some embodiments, the query instruction acquisition module 410 may further include a second receiving unit, a sending unit, and a third receiving unit.
The second receiving unit can be used for receiving second prompt information sent by the target intelligent equipment, and the second prompt information is used for representing the state change of the target intelligent equipment; the sending unit may be configured to send the second prompt information to the gateway; the third receiving unit may be configured to receive a state parameter query instruction for the target intelligent device sent by the gateway, where the state parameter query instruction is sent by the gateway after receiving the second prompt message.
In some embodiments, the device status query apparatus 400 may further include a receiving module and a storage module.
The receiving module may be configured to receive the configuration file of each intelligent device sent by the gateway before the configuration file determining module 420 determines the target configuration file corresponding to the target intelligent device based on the state parameter query instruction; the storage module can be used for uniformly storing the configuration file of each intelligent device through the universal firmware.
In some embodiments, the device status query apparatus 400 may also include a replacement module.
The replacing module may be configured to replace the configuration file of the intelligent device stored in the general firmware with the new configuration file of the intelligent device if the new configuration file of at least one intelligent device sent by the gateway is received after the storage module uniformly stores the configuration file of each intelligent device through the general firmware.
In some implementations, the polling module 430 may include a determination unit and a polling unit.
The determining unit may be configured to determine a polling rule and a communication protocol based on the target profile; the polling unit may be configured to poll the target smart device based on a polling rule after establishing a communication connection with the target smart device based on the communication protocol.
In some embodiments, the device state query apparatus 400 may further include an initial parameter acquisition module, a calculation module, a state determination module, a state change determination module, and a state unchanged determination module.
The initial parameter obtaining module may be configured to obtain an initial state parameter of the target intelligent device before the sending module 440 determines that the state of the target intelligent device changes according to the current state parameter, and sends the current state parameter to the gateway; the calculation module can be used for calculating a parameter difference value between the current state parameter and the initial state parameter; the state determining module can be used for determining whether the state of the target intelligent device changes according to the parameter difference value and the difference value threshold value; the state change determining module may be configured to determine that a state of the target intelligent device changes when the parameter difference is greater than a difference threshold; the state unchanged determining module may be configured to determine that the state of the target smart device is unchanged when the parameter difference is less than or equal to the difference threshold.
The scheme provided by the application is applied to the wireless module, the wireless module is connected with the gateway, the wireless module is connected with at least one intelligent device, the wireless module obtains a state parameter query instruction aiming at the target intelligent device and determines a target configuration file corresponding to the target intelligent device based on the state parameter query instruction, wherein each intelligent device is preconfigured with the corresponding configuration file and polls the target intelligent device based on the target configuration file so as to obtain the current state parameter of the target intelligent device, when the state of the target intelligent device is determined to change according to the current state parameter, the current state parameter is sent to the gateway, the gateway is connected with different intelligent devices in a communication mode based on a single wireless module, a plurality of wireless modules are not required to be configured in the intelligent home system, and the installation cost of the intelligent home system is reduced.
It should be noted that, in the present specification, each embodiment is described in a progressive manner, and each embodiment is mainly described as different from other embodiments, and identical and similar parts between the embodiments are all enough to be referred to each other. For the apparatus class embodiments, the description is relatively simple as it is substantially similar to the method embodiments, and reference is made to the description of the method embodiments for relevant points. Any of the described processing manners in the method embodiment may be implemented by a corresponding processing module in the device embodiment, which is not described in detail in the device embodiment.
In addition, each functional module in each embodiment of the present application may be integrated into one processing module, or each module may exist alone physically, or two or more modules may be integrated into one module. The integrated modules may be implemented in hardware or in software functional modules.
Referring to fig. 7, a functional block diagram of an electronic device 600 according to another embodiment of the present application is shown, where the electronic device 600 may include one or more of the following components: memory 610, processor 620, and one or more applications, wherein the one or more applications may be stored in memory 610 and configured to be executed by the one or more processors 620, the one or more applications configured to perform the method as described in the foregoing method embodiments.
The Memory 610 may include a random access Memory (Random Access Memory, RAM) or a Read-Only Memory (Read-Only Memory). Memory 610 may be used to store instructions, programs, code, sets of codes, or sets of instructions. The memory 610 may include a stored program area and a stored data area, wherein the stored program area may store instructions for implementing an operating system, instructions for implementing at least one function (such as obtaining a status parameter query instruction, determining a target configuration file, polling a target smart device, obtaining a current status parameter, determining a change in a status of the target smart device, sending the current status parameter to a gateway, receiving a first hint information, generating a status parameter query instruction, receiving a second hint information, sending the second hint information, receiving a configuration file, storing a configuration file, receiving a new configuration file, replacing a configuration file, determining a polling rule, determining a communication protocol, obtaining an initial status parameter, calculating a parameter difference value, etc.), instructions for implementing various method embodiments described below, etc. The storage data area may also store data created by the electronic device 600 in use (e.g., status parameter query instructions, target configuration files, current status parameters, first hint information, status change, second hint information, new configuration files, polling rules, communication protocols, initial status parameters, parameter differences, and difference thresholds), etc.
Processor 620 may include one or more processing cores. The processor 620 utilizes various interfaces and lines to connect various portions of the overall electronic device 600, perform various functions of the electronic device 600, and process data by executing or executing instructions, programs, code sets, or instruction sets stored in the memory 610, and invoking data stored in the memory 610. Alternatively, the processor 620 may be implemented in hardware in at least one of digital signal processing (Digital Signal Processing, DSP), field programmable gate array (Field-Programmable Gate Array, FPGA), programmable logic array (Programmable Logic Array, PLA). The processor 620 may integrate one or a combination of several of a central processing unit (Central Processing Unit, CPU), an image processor (Graphics Processing Unit, GPU), and a modem, etc. The CPU mainly processes an operating system, a user interface, an application program and the like; the GPU is used for being responsible for rendering and drawing of display content; the modem is used to handle wireless communications. It will be appreciated that the modem may not be integrated into the processor 620 and may be implemented solely by a single communication chip.
Referring to fig. 8, a block diagram of a computer readable storage medium according to an embodiment of the present application is shown. The computer readable storage medium 700 has stored therein program code 710, the program code 710 being executable by a processor to perform the method described in the method embodiments described above.
The computer readable storage medium 700 may be an electronic memory such as a flash memory, an EEPROM (electrically erasable programmable read only memory), an EPROM, a hard disk, or a ROM. Optionally, the computer readable storage medium 700 comprises a non-volatile computer readable medium (non-transitory computer-readable storage medium). The computer readable storage medium 700 has memory space for program code 710 that performs any of the method steps described above. The program code can be read from or written to one or more computer program products. Program code 710 may be compressed, for example, in a suitable form.
The scheme provided by the application is applied to the wireless module, the wireless module is connected with the gateway, the wireless module is connected with at least one intelligent device, the wireless module obtains a state parameter query instruction aiming at the target intelligent device and determines a target configuration file corresponding to the target intelligent device based on the state parameter query instruction, wherein each intelligent device is preconfigured with the corresponding configuration file and polls the target intelligent device based on the target configuration file so as to obtain the current state parameter of the target intelligent device, when the state of the target intelligent device is determined to change according to the current state parameter, the current state parameter is sent to the gateway, the gateway is connected with different intelligent devices in a communication mode based on a single wireless module, a plurality of wireless modules are not required to be configured in the intelligent home system, and the installation cost of the intelligent home system is reduced.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present application, and are not limiting thereof; although the present application has been described in detail with reference to the foregoing embodiments, one of ordinary skill in the art will appreciate that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not drive the essence of the corresponding technical solutions to depart from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims (9)

1. The device state query method is characterized by being applied to a wireless module, wherein the wireless module is connected with a gateway and is connected with at least one intelligent device, and the device state query method comprises the following steps:
acquiring a state parameter query instruction aiming at target intelligent equipment;
determining a target configuration file corresponding to the target intelligent equipment based on the state parameter query instruction, wherein each intelligent equipment is preconfigured with a corresponding configuration file;
polling the target intelligent device based on the target configuration file to obtain current state parameters of the target intelligent device;
When the state of the target intelligent equipment is determined to change according to the current state parameter, the current state parameter is sent to the gateway;
the polling the target smart device based on the target profile includes:
determining a polling rule and a communication protocol based on the target profile, the polling rule including a rule of polling period information and device address information;
after establishing a communication connection with the target smart device based on the communication protocol, polling the target smart device based on the polling rule.
2. The device status query method of claim 1, wherein the obtaining a status parameter query instruction for a target smart device comprises:
receiving first prompt information sent by target intelligent equipment, wherein the first prompt information is used for representing the state change of the target intelligent equipment;
and generating a state parameter query instruction aiming at the target intelligent equipment based on the first prompt information.
3. The device status query method of claim 1, wherein the obtaining a status parameter query instruction for a target smart device comprises:
Receiving second prompt information sent by target intelligent equipment, wherein the second prompt information is used for representing the state change of the target intelligent equipment;
sending the second prompt message to the gateway;
and receiving a state parameter query instruction which is sent by the gateway and is aimed at the target intelligent equipment, wherein the state parameter query instruction is sent after the gateway receives the second prompt information.
4. The device status query method of claim 1, further comprising, prior to the determining, based on the status parameter query instruction, a target profile corresponding to the target smart device:
receiving a configuration file of each intelligent device sent by the gateway;
and uniformly storing the configuration file of each intelligent device through the universal firmware.
5. The device status query method of claim 4, further comprising, after said collectively storing the configuration file of each smart device by the generic firmware:
and if the new configuration file of at least one intelligent device sent by the gateway is received, replacing the configuration file of the intelligent device stored in the universal firmware with the new configuration file of the intelligent device.
6. The device status query method according to any one of claims 1 to 5, further comprising, before said sending the current status parameter to the gateway when it is determined that the status of the target smart device has changed according to the current status parameter:
acquiring initial state parameters of the target intelligent equipment;
calculating a parameter difference between the current state parameter and the initial state parameter;
determining whether the state of the target intelligent equipment changes according to the parameter difference value and the difference value threshold;
when the parameter difference value is larger than the difference value threshold value, determining that the state of the target intelligent equipment is changed;
and when the parameter difference value is smaller than or equal to the difference value threshold value, determining that the state of the target intelligent equipment is unchanged.
7. A device state query apparatus, applied to a wireless module, where the wireless module is connected to a gateway, and where the wireless module is connected to at least one intelligent device, the device state query apparatus comprising:
the query instruction acquisition module is used for acquiring a state parameter query instruction aiming at the target intelligent equipment;
The configuration file determining module is used for determining a target configuration file corresponding to the target intelligent equipment based on the state parameter query instruction, wherein each intelligent equipment is pre-configured with the corresponding configuration file;
the polling module is used for polling the target intelligent equipment based on the target configuration file so as to obtain the current state parameters of the target intelligent equipment;
the sending module is used for sending the current state parameter to the gateway when the state of the target intelligent device is determined to change according to the current state parameter;
the polling module comprises a determining unit and a polling unit;
the determining unit is used for determining a polling rule and a communication protocol based on the target configuration file, wherein the polling rule comprises a rule of polling period information and device address information;
the polling unit is used for polling the target intelligent device based on the polling rule after the communication connection with the target intelligent device is established based on the communication protocol.
8. An electronic device, comprising:
a memory;
one or more processors coupled with the memory;
one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by one or more processors, the one or more applications configured to perform the device state query method of any of claims 1-6.
9. A computer readable storage medium having stored therein program code which is callable by a processor to perform the device status query method of any one of claims 1 to 6.
CN202210301965.9A 2022-03-24 2022-03-24 Equipment state query method, query device, electronic equipment and storage medium Active CN114553626B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210301965.9A CN114553626B (en) 2022-03-24 2022-03-24 Equipment state query method, query device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210301965.9A CN114553626B (en) 2022-03-24 2022-03-24 Equipment state query method, query device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN114553626A CN114553626A (en) 2022-05-27
CN114553626B true CN114553626B (en) 2024-03-08

Family

ID=81666025

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210301965.9A Active CN114553626B (en) 2022-03-24 2022-03-24 Equipment state query method, query device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114553626B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115240369A (en) * 2022-07-21 2022-10-25 天津君秒安减灾科技有限公司 Internet of things loudspeaker voice broadcasting system based on earthquake early warning

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105516185A (en) * 2015-12-30 2016-04-20 广东顺德中山大学卡内基梅隆大学国际联合研究院 Multi-protocol gateway equipment
CN110673502A (en) * 2019-10-14 2020-01-10 珠海格力电器股份有限公司 Quick response method and system of intelligent device, storage medium and network side device
CN114143201A (en) * 2021-11-12 2022-03-04 杭州极简物控科技有限公司 Power distribution network fusion terminal equipment control method based on low code technology

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104618440B (en) * 2014-12-31 2018-03-23 腾讯科技(深圳)有限公司 Smart machine control method and device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105516185A (en) * 2015-12-30 2016-04-20 广东顺德中山大学卡内基梅隆大学国际联合研究院 Multi-protocol gateway equipment
CN110673502A (en) * 2019-10-14 2020-01-10 珠海格力电器股份有限公司 Quick response method and system of intelligent device, storage medium and network side device
CN114143201A (en) * 2021-11-12 2022-03-04 杭州极简物控科技有限公司 Power distribution network fusion terminal equipment control method based on low code technology

Also Published As

Publication number Publication date
CN114553626A (en) 2022-05-27

Similar Documents

Publication Publication Date Title
KR100605209B1 (en) Converting apparatus for network
WO2020223854A1 (en) Device network configuration method and apparatus, electronic device and storage medium
CN113348725B (en) Device operation method, device, gateway, electronic device and computer readable medium
CN107991891B (en) Method and system for adjusting environmental parameters and user equipment
CN106909081B (en) Household electrical appliance and expansion platform based on same
CN111965989B (en) System updating method and device, intelligent home control panel and storage medium
CN114553626B (en) Equipment state query method, query device, electronic equipment and storage medium
CN112804730B (en) Equipment interconnection method, device, server, intelligent equipment and storage medium
EP4274190A1 (en) Smart device control method and apparatus, electronic device, and computer readable medium
CN113572799A (en) Method and device for accessing equipment to control platform and server
CN112764351A (en) Control method and device of intelligent device, electronic device and storage medium
CN112596406A (en) Control method and device of intelligent equipment, control panel and storage medium
CN108234562B (en) Equipment control method, control equipment and controlled equipment
CN109981424B (en) Linkage scheme processing method and device, electronic equipment and storage medium
CN111245677A (en) Communication abnormity reporting method and device, electronic equipment and storage medium
US20210148596A1 (en) Air Conditioner Networking Method and Terminal
CN113672146A (en) Light control method, device, system, electronic equipment and storage medium
CN112037785A (en) Control method and device of intelligent equipment, electronic equipment and storage medium
CN109936488B (en) Linkage scheme processing method and device, electronic equipment and storage medium
JP4838096B2 (en) Home appliance communication control system
CN110324217B (en) Equipment triggering control method and device, electronic equipment and storage medium
EP3022869B1 (en) Communication method and apparatus using smart module in home network system
CN114265327B (en) Sleep control method and device of intelligent household equipment, processor and electronic equipment
JP6916683B2 (en) Communication module and communication method
CN114326420A (en) Intelligent grouping method and device for equipment, intelligent equipment and storage medium

Legal Events

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