A method, device and storage medium for implementing an intelligent gateway

By obtaining device access events and dividing the device list, the signal strength and communication active time are used to determine the online status of the device, which solves the problem of low accuracy in determining the personnel in the room in the existing technology, and achieves more efficient and convenient personnel status determination.

CN114339949BActive Publication Date: 2024-09-03CHENGDU AOTI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210095285.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-01-26
Publication Date
2024-09-03
Estimated Expiration
2042-01-26

AI Technical Summary

Technical Problem

In the existing technology, the judgment of the situation of people in the room is greatly affected by external influences, the judgment accuracy is low, and it cannot meet the judgment needs of multiple people.

Method used

By obtaining device access events, the device list is divided, the authenticity of the device access method is judged, the non-fixed device access list is obtained, the signal strength and communication active time are used to determine the online status of the device, and then determine the status of the people in the room.

Benefits of technology

It improves the accuracy and efficiency of judging the situation of people in the room, reduces the use of external measurement equipment, reduces costs, and is suitable for multi-scenario applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114339949B
    Figure CN114339949B
Patent Text Reader

Abstract

The present invention discloses an implementation method, device and storage medium of an intelligent gateway, including: S1, obtaining a device access event, and obtaining an access device list according to the device access event; S2, dividing the access device list according to the device access mode, and obtaining a first device list and a second device list; S3, using a first judgment method to judge the authenticity of information access on the first device list, and obtaining a third device list; using a second judgment method to judge the authenticity of information access on the second device list, and obtaining a fourth device list; S4, extracting non-fixed devices from the third device list and the fourth device list, and obtaining a non-fixed device access list. The access device list is divided into different device lists according to the device access mode, and the real information of device access is judged according to different judgment methods for different device lists, and a non-fixed device access list is obtained, and the personnel situation in the room is judged.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of communication technology, and in particular to an implementation method, device and storage medium of an intelligent gateway. Background Art

[0002] At present, the judgment of the presence of people in a room in the market mostly relies on infrared detection equipment, cameras or door magnetic devices, etc. However, infrared detection equipment is greatly affected by the static state of people and light, and has a high misjudgment rate; cameras cannot be used in many occasions because they cannot guarantee the privacy of the people being photographed, and door magnetic devices need to judge based on the number of times the door is closed, which in principle cannot meet the situation where there are multiple people entering and leaving the room. Summary of the invention

[0003] The technical problem to be solved by the present invention is that the judgment of the situation of people in the room in the prior art is greatly affected by external factors and the judgment accuracy is low. The purpose is to provide an implementation method, device and storage medium of an intelligent gateway, by judging the devices connected to the room and their real information, obtaining the connection status of non-fixed devices, and judging the situation of people in the room, thereby improving the accuracy of the judgment of the situation of people in the room.

[0004] The present invention is achieved through the following technical solutions:

[0005] A first aspect of the present invention provides a method for implementing an intelligent gateway, comprising:

[0006] S1. Obtain device access events, and obtain access device lists according to the device access events;

[0007] S2. Divide the access device list according to the device access mode to obtain a first device list and a second device list;

[0008] S3. Using the first judgment method to judge the authenticity of information access on the first device list, and obtaining a third device list;

[0009] Using the second judgment method to judge the authenticity of information access on the second device list, to obtain a fourth device list;

[0010] S4. Acquire the non-fixed devices in the third device list and the fourth device list, and obtain a non-fixed device access list.

[0011] The present invention obtains a device access event, obtains an access device list, divides the access device list according to the device access mode, obtains a first device list and a second device list, judges the real information of device access for different devices, obtains a third device list and a fourth device list, divides the fixed devices and the non-fixed devices in the third device list and the fourth device list, obtains a non-fixed device access list, judges the situation of people in the room according to the non-fixed device access list, and improves the accuracy of the judgment on the situation of people in the room.

[0012] As a further limitation of the present invention, the acquiring of the device access event includes periodically updating the device access information of the access device.

[0013] As a further limitation of the present invention, the device access mode includes a Wi-Fi connection mode and a Bluetooth connection mode, the first device list is a Wi-Fi connection list, and the second device list is a Bluetooth connection list.

[0014] As a further limitation of the present invention, the first determination method step comprises:

[0015] Monitor the link-break event for each device in the first device list:

[0016] If the device is disconnected, delete it from the list;

[0017] If the device does not experience a link-off event, the device access information is periodically updated, and the device online status is determined based on the device access information until the device experiences a link-off event or the device is determined to be offline for N consecutive times, and the device is deleted from the list, where N is a natural number.

[0018] The device access information includes MAC address, signal strength and communication active time, and the communication active time is the time from the last time the access device communicated with the intelligent gateway to the current time point.

[0019] As a further limitation of the present invention, the online status of the device is determined by determining the signal strength and communication active time of the access device.

[0020] As a further limitation of the present invention, the online condition of the determination device is:

[0021] When r≤R0, t<T0;

[0022] When R0<r≤R1, t<T1;

[0023] When r>R1, t<T2;

[0024] Among them: r is the distance between the terminal device to be determined and the intelligent gateway, r and signal strength are in a negative exponential relationship with a natural constant as the base, t is the active communication time, R0 is the short-distance threshold, R1 is the long-distance threshold, T0 is the short-distance offline determination time, T1 is the medium-distance offline determination time, and T2 is the long-distance offline determination time.

[0025] As a further limitation of the present invention, the second method for determining the second device list to determine the real information of device access includes:

[0026] Monitor the link-break event for the second device list:

[0027] If a link break event occurs, the corresponding device is offline and the device is deleted from the list.

[0028] As a further limitation of the present invention, obtaining the non-fixed device access list includes acquiring a unique device identifier, a device type, and the number of devices of the same type of the accessed non-fixed device.

[0029] The second aspect of the present invention provides an implementation device of an intelligent gateway, including a judgment module, a parameter configuration module and an access device monitoring module:

[0030] The judgment module is used to judge the device access mode, device online status, non-fixed device access type and access quantity according to the data of the parameter configuration module and the data of the access device monitoring module;

[0031] The parameter configuration module is used to configure fixed device parameters and parameters required for device online determination;

[0032] The access device monitoring module is used to obtain device access events, monitor link break events on access devices, and store device access information.

[0033] A third aspect of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method for implementing an intelligent gateway described above is implemented.

[0034] Compared with the prior art, the present invention has the following advantages and beneficial effects:

[0035] 1. By judging the access mode and real information of the equipment in the room, the access status of non-fixed equipment is obtained, and the situation of the people in the room is judged, which improves the accuracy and efficiency of judgment;

[0036] 2. By judging the corresponding real information of device access for multiple access modes of the access device, the device access status can be queried in real time, thus improving the accuracy of data acquisition;

[0037] 3. Reduce the use of external measurement equipment, reduce costs, enable multi-scenario applications, and improve convenience. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] In order to more clearly illustrate the technical solutions of the exemplary embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. It should be understood that the following drawings only illustrate certain embodiments of the present invention and should not be regarded as limiting the scope. For those of ordinary skill in the art, other relevant drawings can be obtained based on these drawings without creative work. In the drawings:

[0039] Figure 1 A schematic diagram of a method for implementing an intelligent gateway in an embodiment of the present invention;

[0040] Figure 2 A schematic diagram of a device for implementing an intelligent gateway in an embodiment of the present invention;

[0041] Figure 3 A flow chart of a method for implementing an intelligent gateway in an embodiment of the present invention;

[0042] Figure 4 The present invention is a flowchart of a second method for implementing an intelligent gateway in an embodiment of the present invention. DETAILED DESCRIPTION

[0043] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with embodiments and drawings. The exemplary implementation modes of the present invention and their description are only used to explain the present invention and are not intended to limit the present invention.

[0044] Example 1

[0045] A first aspect of this embodiment provides a method for implementing an intelligent gateway, including:

[0046] S1. Obtain device access events, and obtain access device lists according to the device access events;

[0047] S2. Divide the access device list according to the device access mode to obtain a first device list and a second device list;

[0048] S3. Using the first judgment method to judge the authenticity of information access on the first device list, and obtaining a third device list;

[0049] Using the second judgment method to judge the authenticity of information access on the second device list, to obtain a fourth device list;

[0050] S4. Extract non-fixed devices from the third device list and the fourth device list to obtain a non-fixed device access list.

[0051] By acquiring device access events, obtaining an access device list, dividing the access device list according to the device access method, obtaining a first device list and a second device list, judging the real information of device access for different devices, obtaining a third device list and a fourth device list, dividing the fixed devices and non-fixed devices in the third device list and the fourth device list, obtaining a non-fixed device access list, judging the situation of people in the room according to the non-fixed device access list, and improving the accuracy of judging the situation of people in the room.

[0052] In some possible embodiments, obtaining device access events includes periodically updating device access information of access devices to improve the accuracy of the access device list obtained. Since the access device list needs to determine the authenticity of its access, the device access information of the access device list is periodically updated, and the signal strength and communication active time in the device access information are continuously updated, so that the activities of people in the room can be dynamically determined. Obtaining device access events also includes real-time monitoring of access devices. If device access is detected, the device access list is updated.

[0053] In some possible embodiments, the device access mode includes a Wi-Fi connection mode and a Bluetooth connection mode. The first device list is a Wi-Fi connection list, and the second device list is a Bluetooth connection list. By dividing different connection modes and performing real-time query on the device access status, the accuracy of data acquisition is improved.

[0054] In some possible embodiments, the first judgment method step includes: monitoring the link-breaking event for each device in the first device list: if the device has a link-breaking event, the device is deleted from the list; if the device has not had a link-breaking event, the device access information is periodically updated, and the device online status is judged based on the device access information until the device has a link-breaking event or the device is judged to be offline for N consecutive times, and the device is deleted from the list, where N is a natural number; the device access information includes the MAC address, signal strength, and communication active time, and the communication active time is the time from the last time the access device communicated with the intelligent gateway to the current time point. The device online status is judged by judging based on the signal strength and communication active time of the access device, and the device online conditions are:

[0055] When r≤R0, t<T0;

[0056] When R0<r≤R1, t<T1;

[0057] When r>R1, t<T2;

[0058] Among them: r is the distance between the terminal device to be determined and the intelligent gateway, r is calculated by signal strength, r and signal strength are in a negative exponential relationship with a natural constant as the base, t is the communication active time, R0 is the short-distance threshold, R1 is the long-distance threshold, T0 is the short-distance offline determination time, T1 is the medium-distance offline determination time, and T2 is the long-distance offline determination time.

[0059] When the above conditions are not met, but the device exists in the first device access list, it will be deleted from the first device access list. This type of device access event can be determined as other room and external access, and it can be disconnected from the network to prevent network freezes or data information leakage.

[0060] In some possible embodiments, the second judgment method for the second device list to judge the real information of device access includes: monitoring the second device list for link break events: if a link break event occurs, the corresponding device is offline, and the device is deleted from the list.

[0061] In some possible embodiments, obtaining the non-fixed device access list includes obtaining the device unique identifier, device type and number of similar devices of the accessed non-fixed device, where the device unique identifier may be a MAC address, and judging the situation of people in the room based on the non-fixed device access list includes judging the situation of people in the room based on the access type and access number of the non-fixed device, and can judge the usage of the equipment in the room based on the access number of similar devices, thereby making a preliminary judgment on the situation of people in the room.

[0062] The second aspect of this embodiment provides an implementation device of an intelligent gateway, including a judgment module, a parameter configuration module and an access device monitoring module:

[0063] The judgment module is used to judge the device access mode, device online status, non-fixed device access type and access quantity based on the data of the parameter configuration module and the data of the access device monitoring module. The device access mode is judged as Wi-Fi connection mode and Bluetooth connection mode. The device online status judgment is to judge the actual online status of the access device, including the judgment of signal strength and communication active time. By judging the access type and access quantity of non-fixed devices, the device usage in the room can be understood, and thus the situation of people in the room can be judged.

[0064] The parameter configuration module is used to configure fixed device parameters and parameters required for device online determination. The configured fixed device parameters are the fixed device list of the current working environment and various variable parameters required for this method to work. The fixed device parameters include the device unique identification and name information, where the unique identifier is the MAC address. The parameters required for device online determination include signal strength, communication active time, different communication durations at different distances, distance thresholds, and offline determination durations.

[0065] The access device monitoring module is used to obtain device access events, monitor access device disconnection events, and store device access information. When a device is connected, the device information is stored and continuously updated. When the device is detected to be disconnected, the device and device information are deleted.

[0066] A third aspect of this embodiment provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the above-mentioned method for implementing an intelligent gateway is implemented.

[0067] Example 2

[0068] like Figure 1 As shown:

[0069] Query the Wi-Fi access device list, filter the list according to the online device determination conditions, and obtain the final Wi-Fi access device list;

[0070] Query the Bluetooth access device list and directly obtain the final Bluetooth access device list;

[0071] Merge the final Wi-Fi access device list and the final Bluetooth access device list to obtain a total access device list;

[0072] Eliminate all devices in the fixed device list from the total connected devices to obtain a list of connected non-fixed devices;

[0073] Determine the list of connected non-fixed devices to judge the situation of people in the room.

[0074] Obtain the MAC addresses of all devices connected to the smart gateway: The access device monitoring module periodically calls the operating system's functions to obtain relevant information about the access devices, and then determines the current access device status based on this information.

[0075] For Wi-Fi connection, call the function to query the access device list to get the access device information list. For different operating systems, the function to query the Wi-Fi access device list will be different. The device access information includes MAC address, signal strength, and communication active time. The communication active time is the time from the last time this device communicated with the smart gateway to the current time. The working principle of this function is to access the relevant network protocol components and call the WI-FI hardware driver through the scheduling of the operating system to query the real-time status of the WI-FI access device. Whether a certain access device is actually in a connected state needs to be determined based on the signal strength and communication active time of the queried device.

[0076] The conditions for determining whether a device is online are:

[0077] When r≤R0, t<T0;

[0078] When R0<r≤R1, t<T1;

[0079] When r>R1, t<T2;

[0080] Among them: r is the distance between the terminal device to be determined and the smart gateway, r is calculated by signal strength, r and signal strength are in a negative exponential relationship with a natural constant as the base, t is the communication active time, R0 is the short-distance threshold, R1 is the long-distance threshold, which can be configured through the embedded Web interface or configuration interface, T0 is the short-distance offline determination time, T1 is the medium-distance offline determination time, and T2 is the long-distance offline determination time, which can be configured through the embedded Web interface or configuration interface. Eliminate devices that do not meet the online conditions to obtain the final Wi-Fi access device list.

[0081] For Bluetooth connection, call the function to query the access device list. For different operating systems, the function to query the Bluetooth access device list will be different. Get the access device information list, including MAC address, device name, etc. This list is used as the final Bluetooth access device list.

[0082] like Figure 2 As shown:

[0083] Obtain access events and disconnection events of terminal devices from the protocol stack;

[0084] Maintain the total access device list:

[0085] When an access event occurs, the corresponding device is accessed and the device is added to the list;

[0086] If a link break occurs, the corresponding device goes offline and the secondary device is deleted from the list;

[0087] Determine the list of connected non-fixed devices to judge the situation of people in the room.

[0088] The key to obtaining whether the access device is online is to monitor the access events and disconnection events of the terminal device. Regardless of Wi-Fi connection or Bluetooth connection, the protocol stack can obtain the access events and disconnection events of the terminal device through the physical layer. If the protocol stack provides the access events and disconnection events of the terminal device to the business layer through the interface, the business layer can easily obtain and maintain the total access device list, remove all devices in the fixed device list from the total access device list, obtain the list of non-fixed devices that have been connected, and judge the access non-fixed device list to judge the situation of people in the room.

[0089] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. A method for implementing an intelligent gateway, characterized in that: include: S1. Obtain device access events, and obtain access device lists according to the device access events; S2. Divide the access device list according to the device access mode to obtain a first device list and a second device list; S3. Using the first judgment method to judge the authenticity of information access on the first device list, and obtaining a third device list; The device access mode includes a Wi-Fi connection mode and a Bluetooth connection mode, the first device list is a Wi-Fi connection list, and the second device list is a Bluetooth connection list; Using the second judgment method to judge the authenticity of information access on the second device list, to obtain a fourth device list; The first determination method comprises: Monitor the link-break event for each device in the first device list: If the device is disconnected, delete it from the list; If the device does not experience a link-off event, the device access information is periodically updated, and the device online status is determined based on the device access information until the device experiences a link-off event or the device is determined to be offline for N consecutive times, and the device is deleted from the list, where N is a natural number. In Wi-Fi connection mode, call the function to query the access device list to obtain the access device information list. Different operating systems have different functions to query the Wi-Fi access device list. The device access information includes MAC address, signal strength, and communication active time. The communication active time is the time from the last time the device communicated with the smart gateway to the current time point. Through different functions in the Wi-Fi access device list, after being scheduled by the operating system, relevant network protocol components are accessed and the Wi-Fi hardware driver is called to query the real-time status of the Wi-Fi access device; Determine whether a certain access device is actually in a connected state based on the signal strength and active communication time of the device queried; The device online status is determined by judging the signal strength and communication active time of the access device. The device online condition is: When r≤R0, t<T0; When R0<r≤R1, t<T1; When r>R1, t<T2; Where: r is the distance between the terminal device to be determined and the intelligent gateway, r and signal strength are in a negative exponential relationship with a natural constant as the base, t is the communication active time, R0 is the short-distance threshold, R1 is the long-distance threshold, T0 is the short-distance offline determination time, T1 is the medium-distance offline determination time, and T2 is the long-distance offline determination time; S4. Extract non-fixed devices from the third device list and the fourth device list to obtain a non-fixed device access list.

2. The method for implementing the intelligent gateway according to claim 1, characterized in that: The obtaining of the device access event includes periodically updating the device access information of the access device.

3. The method for implementing the intelligent gateway according to claim 1, characterized in that: The second determination method comprises the following steps: Monitor the link-break event for the second device list: If a link break event occurs, the corresponding device is offline and the device is deleted from the list.

4. The method for implementing the intelligent gateway according to claim 1, characterized in that: The obtaining of the non-fixed device access list includes obtaining the device unique identifier, device type and the number of devices of the same type of the accessed non-fixed device.

5. A device for implementing a method of an intelligent gateway, characterized in that: The implementation method of the intelligent gateway applied to any one of claims 1 to 4 comprises a judgment module, a parameter configuration module and an access device monitoring module: The judgment module is used to judge the device access mode, device online status, non-fixed device access type and access quantity according to the data of the parameter configuration module and the data of the access device monitoring module; The parameter configuration module is used to configure fixed device parameters and parameters required for device online determination; The access device monitoring module is used to obtain device access events, monitor link break events on access devices, and store device access information.

6. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the method for implementing an intelligent gateway as described in any one of claims 1 to 4 is implemented.