A Bluetooth automatic table finding and networking method and system
By using the Bluetooth automatic table lookup networking method, the terminal devices and the gateway can automatically form a network, which solves the problems of low intelligence and complex operation, and realizes an efficient and accurate networking process.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-04
- Publication Date
- 2026-04-07
AI Technical Summary
The existing terminal devices and gateways have low intelligence, are complex to operate, and are prone to data entry errors.
The Bluetooth automatic table lookup networking method is adopted. After the terminal device is powered on, it starts Bluetooth broadcasting. The gateway periodically scans the terminal devices, determines the MAC address and performs identity authentication until the automatic networking of all terminal devices is completed.
It enables intelligent and automatic networking of terminal devices and gateways, reducing manual operation, lowering the probability of incorrect data entry, and improving networking efficiency and user experience.
Smart Images

Figure CN118741764B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of intelligent Internet of Things terminal, in particular to a Bluetooth automatic table searching networking method and system. BACKGROUND
[0002] At present, the Internet of Things technology is in a high-speed development stage, and more and more intelligent terminals are connected to the Internet of Things. Intelligentization is to reduce the manual operation of users as much as possible and to complete the connection automatically by the device. Due to the cost of communication, it is impossible for each terminal device to be directly connected to the platform master station. Generally, the terminal device and the gateway are interconnected, and the gateway is used as a bridge to forward data, so as to realize the communication interaction of data collection, control and the like between the platform and the terminal device. The interconnection between multiple terminal devices and the gateway must be networked, and the networking is divided into manual networking and automatic networking. In order to use conveniently and improve user experience, manual networking will be gradually eliminated, and automatic networking technology will be inevitably adopted, and the automatic networking does not need wiring. The patent document with the application number 201320210275.9 discloses a new universal Internet of Things gateway, which comprises a WiFi module, a ZigBee module, a 3G module, a wired terminal identification expansion module, an ARM processor, an input interface, an output interface, a storage module and a power module. All the modules are integrated on a circuit board, and the ARM chip is used as a central processor. The Android system is transplanted to coordinate the work of each module. At present, the interconnection between the terminal device and the gateway is to connect the terminal device and the gateway through wired physical connection, such as power line carrier, RS485, USB and the like. Then, the address, model and other information of the terminal device are recorded and input by an operator. The operator manually inputs the terminal device information into the gateway list of the network to be hung. Then, the terminal device is hung under the downstream device of the corresponding gateway to complete the networking operation. Thereafter, the platform can communicate with the terminal device through the gateway. The wired physical connection between the terminal device and the gateway increases the installation difficulty, such as installing wire slot, wall, etc., which affects the appearance, and the terminal device needs to be known to be hung under which gateway. The manual input of the terminal device information increases the labor cost, and the manual input also increases the error probability, and the intelligent degree is low. The networking using other wireless technologies also has WiFi, ZigBee and other technologies. However, the price of the WiFi module is high, and the power consumption is large, so that the competitiveness of the product is not high, and the transmission rate of ZigBee is low. Therefore, it is urgent to propose a Bluetooth automatic table searching networking method and system to solve the technical problems of low intelligent degree, complex operation and easy input error of the existing terminal device and gateway networking. SUMMARY
[0003] The main purpose of the present application is to provide a Bluetooth automatic table searching networking method and system, which aims to solve the technical problems of low intelligent degree, complex operation and easy input error of the existing terminal device and gateway networking.
[0004] To achieve the above objectives, the present invention provides a Bluetooth automatic table finding and networking method, wherein the Bluetooth automatic table finding and networking method includes the following steps:
[0005] S1. Bluetooth broadcasting starts after the terminal device is powered on;
[0006] S2. The gateway periodically scans for terminal devices that have enabled Bluetooth broadcasting and determines whether the MAC address of the terminal device is in the gateway's device list.
[0007] If so, then the automatic networking between the terminal device and the gateway is completed;
[0008] If not, then perform identity authentication on the terminal device to determine whether the terminal device is a legitimate slave device;
[0009] S3. Repeat step S2 until all terminal devices have completed Bluetooth automatic table lookup and networking.
[0010] In one preferred embodiment, the terminal device broadcasts Bluetooth using a fixed Bluetooth name.
[0011] In one preferred embodiment, the terminal device broadcasts via Bluetooth using its own MAC address.
[0012] In one preferred embodiment, step S2 uses the DES or 3DES algorithm to perform identity authentication and recognition on the terminal device.
[0013] In one preferred embodiment, step S2 involves performing identity authentication and identification on the terminal device, specifically as follows:
[0014] The gateway sends the key to the terminal device;
[0015] The terminal device receives the key, encrypts it, converts it into first ciphertext, and transmits the first ciphertext to the gateway;
[0016] The gateway encrypts the key twice to obtain a second ciphertext, and compares the second ciphertext with the first ciphertext. If the comparison results of the first ciphertext and the second ciphertext are consistent, the authentication is successful.
[0017] In one preferred embodiment, prior to step S3, the method further includes:
[0018] The terminal device's Bluetooth name will be changed to LOCK after the terminal device and gateway have automatically formed a network, and the terminal device information will be stored and updated to the device list.
[0019] In one preferred embodiment, step S3 specifically comprises:
[0020] The main station performs repeated scans and uploads the device list obtained after all terminal devices have automatically formed a network with the gateway to the main station, thereby completing the automatic Bluetooth lookup and networking of all terminal devices.
[0021] A system including the aforementioned Bluetooth automatic table lookup networking method includes: a gateway and several terminal devices; the gateway is communicatively connected to the several terminal devices.
[0022] In the above technical solution of the present invention, the Bluetooth automatic table lookup networking method includes the following steps: after the terminal device is powered on, it starts Bluetooth broadcasting; the gateway periodically scans terminal devices that have enabled Bluetooth broadcasting and determines whether the MAC address of the terminal device is in the gateway's device list; if so, the automatic networking between the terminal device and the gateway is completed; if not, the terminal device is authenticated and identified to determine whether the terminal device is a legitimate slave device; the above steps are repeated until the automatic Bluetooth table lookup networking of all terminal devices is completed. The present invention solves the technical problems of low intelligence, complex operation, and easy entry errors in existing terminal device and gateway networking.
[0023] In this invention, terminal devices are queried by Bluetooth name. After the terminal device is authenticated, its Bluetooth name can be modified to avoid repeated searches. Attached Figure Description
[0024] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the structures shown in these drawings without creative effort.
[0025] Figure 1 This is a schematic diagram of a Bluetooth automatic table finding and networking method according to an embodiment of the present invention.
[0026] The realization of the objective, functional characteristics and advantages of the present invention will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0027] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0028] Furthermore, in this invention, descriptions involving "first," "second," etc., are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Therefore, a feature defined with "first" or "second" may explicitly or implicitly include at least one of that feature.
[0029] Furthermore, the technical solutions of the various embodiments of the present invention can be combined with each other, but only if they are based on the ability of those skilled in the art to implement them. When the combination of technical solutions is contradictory or cannot be implemented, it should be considered that such combination of technical solutions does not exist and is not within the scope of protection claimed by the present invention.
[0030] See Figure 1 According to one aspect of the present invention, the present invention provides a Bluetooth automatic table finding and networking method, wherein the Bluetooth automatic table finding and networking method includes the following steps:
[0031] S1. Bluetooth broadcasting starts after the terminal device is powered on;
[0032] S2. The gateway periodically scans for terminal devices that have enabled Bluetooth broadcasting and determines whether the MAC address of the terminal device is in the gateway's device list.
[0033] If so, then the automatic networking between the terminal device and the gateway is completed;
[0034] If not, then perform identity authentication on the terminal device to determine whether the terminal device is a legitimate slave device;
[0035] S3. Repeat step S2 until all terminal devices have completed Bluetooth automatic table lookup and networking.
[0036] Specifically, in this embodiment, after the terminal device is powered on, it enables Bluetooth broadcasting and broadcasts using a fixed Bluetooth name, such as "SLAVE". This invention does not impose specific limitations and can be set as needed.
[0037] Specifically, in this embodiment, after the terminal device is powered on, it enables Bluetooth broadcasting, and can also broadcast via Bluetooth using the MAC address of the terminal device that initiates the Bluetooth broadcast.
[0038] Specifically, in this embodiment, the gateway periodically scans for terminal devices with the Bluetooth name "SLAVE". If the terminal device's MAC address exists in the gateway's device list, the gateway directly changes the current terminal device's Bluetooth name to LOCK and stores and updates the terminal device information to the device list. If the terminal device's MAC address is not in the gateway's device list, it is considered that a new terminal device has been added downstream. The gateway then needs to perform identity authentication on the new terminal device to determine whether it is a legitimate slave device. If the identity authentication is successful, the current terminal device is identified as a legitimate slave device. The gateway then adds the current terminal device information to the gateway's device list, changes the Bluetooth name of the terminal device that has completed automatic networking with the gateway to LOCK, and stores and updates the terminal device information to the device list. As a result, the gateway will not scan for the current terminal device in the next scan.
[0039] Specifically, in this embodiment, step S2 uses the DES or 3DES algorithm to perform identity authentication and recognition on the terminal device.
[0040] Specifically, in this embodiment, the identity authentication and identification of the terminal device in step S2 is as follows:
[0041] The gateway sends the key to the terminal device;
[0042] The terminal device receives the key, encrypts it, converts it into first ciphertext, and transmits the first ciphertext to the gateway;
[0043] The gateway encrypts the key twice to obtain a second ciphertext, and compares the second ciphertext with the first ciphertext. If the comparison results of the first ciphertext and the second ciphertext are consistent, the authentication is successful.
[0044] Specifically, in this embodiment, step S3 is as follows:
[0045] The main station performs repeated scans and uploads the device list obtained after all terminal devices have automatically formed a network with the gateway to the main station, thereby completing the automatic Bluetooth lookup and networking of all terminal devices.
[0046] According to one aspect of the present invention, the present invention provides a Bluetooth automatic table finding networking system, wherein the Bluetooth automatic table finding networking system includes: a gateway and a plurality of terminal devices; the gateway is communicatively connected to the plurality of terminal devices.
[0047] Specifically, in this embodiment, the gateway or several of the terminal devices may be Bluetooth modules, that is, the Bluetooth module may be used as a gateway or a terminal device; the Bluetooth module uses a WS8100 chip, which is not specifically limited in this invention, and can be set as needed.
[0048] Specifically, in this embodiment, the gateway and several terminal devices may be WiFi wireless modules or ZigBee wireless modules.
[0049] To facilitate understanding of the terminology related to this invention, the following explanations are provided:
[0050] The MAC address is a unique ID for the Bluetooth module, used for identification.
[0051] The above are merely preferred embodiments of the present invention and do not limit the patent scope of the present invention. All equivalent structural transformations made using the contents of the present invention's specification and drawings under the inventive concept of the present invention, or direct / indirect applications in other related technical fields, are included within the patent protection scope of the present invention.
Claims
1. A Bluetooth automatic table finding and networking method, characterized in that, Includes the following steps: S1. Bluetooth broadcasting starts after the terminal device is powered on; S2. The gateway periodically scans for terminal devices that have enabled Bluetooth broadcasting and determines whether the MAC address of the terminal device is in the gateway's device list. If so, then the automatic networking between the terminal device and the gateway is completed; If not, then perform identity authentication on the terminal device to determine whether the terminal device is a legitimate slave device; The identity authentication and identification of the terminal device in step S2 is specifically as follows: The gateway sends the key to the terminal device; The terminal device receives the key, encrypts it, converts it into first ciphertext, and transmits the first ciphertext to the gateway; The gateway encrypts the key twice to obtain a second ciphertext, and compares the second ciphertext with the first ciphertext. If the comparison results of the first ciphertext and the second ciphertext are consistent, the authentication is successful. S3. Change the Bluetooth name of the terminal device that has completed automatic networking with the gateway to LOCK, and store and update the terminal device information to the device list; repeat step S2 until all terminal devices have completed automatic Bluetooth lookup and networking.
2. The Bluetooth automatic table finding and networking method according to claim 1, characterized in that, In step S1, the terminal device broadcasts Bluetooth using a fixed Bluetooth name.
3. The Bluetooth automatic table finding and networking method according to claim 1, characterized in that, In step S1, the terminal device broadcasts its own MAC address via Bluetooth.
4. A Bluetooth automatic table finding and networking method according to any one of claims 1-3, characterized in that, In step S2, the DES or 3DES algorithm is used to authenticate and identify the terminal device.
5. A Bluetooth automatic table finding and networking method according to any one of claims 1-3, characterized in that, Step S3 specifically involves: The main station performs repeated scans and uploads the device list obtained after all terminal devices have automatically formed a network with the gateway to the main station, thereby completing the automatic Bluetooth lookup and networking of all terminal devices.
6. A system comprising the Bluetooth automatic table lookup and networking method according to any one of claims 1-5, characterized in that, include: A gateway and several terminal devices; the gateway is communicatively connected to the several terminal devices.
Citation Information
Patent Citations
Novel universal Internet-of-things gateway
CN203261357U
Bluetooth matrix networking method and system, terminal and storage medium
CN113784455A