CN115334486B - Bluetooth communication method and Bluetooth system - Google Patents

Bluetooth communication method and Bluetooth system Download PDF

Info

Publication number
CN115334486B
CN115334486B CN202211270984.6A CN202211270984A CN115334486B CN 115334486 B CN115334486 B CN 115334486B CN 202211270984 A CN202211270984 A CN 202211270984A CN 115334486 B CN115334486 B CN 115334486B
Authority
CN
China
Prior art keywords
equipment
broadcast information
peripheral
central
target
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
CN202211270984.6A
Other languages
Chinese (zh)
Other versions
CN115334486A (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.)
Chengdu Analog Circuit Technology Inc
Original Assignee
Chengdu Analog Circuit Technology Inc
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 Chengdu Analog Circuit Technology Inc filed Critical Chengdu Analog Circuit Technology Inc
Priority to CN202211270984.6A priority Critical patent/CN115334486B/en
Publication of CN115334486A publication Critical patent/CN115334486A/en
Application granted granted Critical
Publication of CN115334486B publication Critical patent/CN115334486B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W28/00Network traffic management; Network resource management
    • H04W28/02Traffic management, e.g. flow control or congestion control
    • H04W28/0289Congestion control
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/06Selective distribution of broadcast services, e.g. multimedia broadcast multicast service [MBMS]; Services to user groups; One-way selective calling services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. TPC [Transmission Power Control], power saving or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0209Power saving arrangements in terminal devices
    • H04W52/0225Power saving arrangements in terminal devices using monitoring of external events, e.g. the presence of a signal
    • H04W52/0248Power saving arrangements in terminal devices using monitoring of external events, e.g. the presence of a signal dependent on the time of the day, e.g. according to expected transmission activity
    • 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
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Abstract

The invention discloses a Bluetooth communication method and a Bluetooth system, and relates to the technical field of wireless communication. When the method is applied to the center equipment, the method comprises the following steps: setting a central equipment identification number and storing the identification number as an MAC address of the central equipment; wherein the center device identification number includes: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices; receiving and caching broadcast information sent by peripheral equipment, and sending a scanning request; after receiving broadcast information sent by peripheral equipment, analyzing the broadcast information, screening target peripheral equipment, and extracting effective data in the target peripheral equipment; and continuously receiving and processing the broadcast information sent by the next peripheral equipment. According to the technical scheme, the identification number and the broadcast information of the central equipment are matched to quickly match the target equipment, so that the processing time of the central equipment can be reduced, and the communication efficiency is improved.

Description

Bluetooth communication method and Bluetooth system
Technical Field
The present invention relates to the field of wireless communication technologies, and in particular, to a bluetooth communication method and a bluetooth system.
Background
With the maturity of BLE (Bluetooth Low Energy) technology, more and more BLE communication devices are present in the environment. As is well known, in BLE wireless communication, broadcasting (broadcasting) is a very important position, a peripheral device needs to send information by means of broadcasting to inform the outside of the existence of the peripheral device, and a central device needs to explore nearby peripheral devices by means of received broadcast information.
However, the BLE broadcasting can only work on three wireless channels 37, 38 and 39 currently, if a large amount of BLE broadcasting exists in the environment at a certain time node, channel congestion can be caused, interference can be caused among BLE devices, and a large amount of work needs to be spent by a central device to process received broadcasting in a screening manner and remove repeated information, which all affect communication quality; in the broadcast transmission process, after the central device acquires the data of the peripheral device, the peripheral device still continues to broadcast until the peripheral device is closed, so that the power consumption is increased, the service life of the BLE device is shortened, and the like.
Therefore, the technical problems to be solved at present are as follows:
1. how to handle channel interference due to high concurrency;
2. how to quickly screen useful information, improve communication efficiency and reduce channel congestion;
3. how to switch states in real time to control power consumption;
in view of the above technical problems, in the current BLE wireless communication device, there is no systematic method for solving the above problems, and a periodic broadcast mode is generally adopted to avoid the above problems. However, the periodic broadcast mode is that the broadcast is turned on and off at regular time during the working process, and cannot be turned off immediately, and in the period of turning on the broadcast, there are still many useless signals in the environment to interfere with the communication of the central device, and the peripheral device cannot confirm whether the data is received by the target central device, which results in low communication efficiency.
Disclosure of Invention
The invention mainly aims to provide a Bluetooth communication method and a Bluetooth system, aiming at improving the communication efficiency.
In order to achieve the above object, the present invention provides a bluetooth communication method, applied to a center device, including:
setting a central equipment identification number and storing the identification number as an MAC address of the central equipment; wherein the center device identification number includes: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices;
receiving and caching broadcast information sent by peripheral equipment, and sending a scanning request;
after receiving broadcast information sent by peripheral equipment, analyzing the broadcast information, screening target peripheral equipment, and extracting effective data in the target peripheral equipment;
and continuously receiving and processing the broadcast information sent by the next peripheral equipment.
Preferably, the center device identification number includes an identification part of two bytes and an ID part of four bytes.
Preferably, the broadcast information includes a peripheral device identification number, which is stored as a MAC address of the peripheral device, and includes an identification part for determining whether it is the same group of devices and an ID part for distinguishing different devices.
Preferably, analyzing the broadcast information and screening the target peripheral device further includes matching the received broadcast information according to the identification number of the central device:
if the identification part of the peripheral equipment is the same as the identification part in the received broadcast information, judging that the peripheral equipment sending the broadcast information is target equipment, and extracting effective data in the broadcast information for storage;
if the identification part is different from the identification part in the received broadcast information, the peripheral equipment which sends the broadcast information is judged not to be the target equipment, and the broadcast information is abandoned.
The invention also provides a Bluetooth communication method, which is applied to peripheral equipment and comprises the following steps:
setting a peripheral equipment identification number, and storing the peripheral equipment identification number as an MAC address of the peripheral equipment identification number, wherein the peripheral equipment identification number comprises: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices;
sending broadcast information to the central equipment, and monitoring a scanning request sent by the central equipment;
after receiving the scanning request from the center equipment, analyzing the scanning request, screening the target center equipment, and entering dormancy according to the scanning request of the target center equipment.
Preferably, the peripheral device identification number includes an identification portion of two bytes and an ID portion of four bytes.
Preferably, the scan request includes a center device identification number, which is stored as a MAC address of the center device and includes an identification part for determining whether the center device is the same group of devices and an ID part for distinguishing different devices.
Preferably, the analyzing the scanning request and the screening of the target central device further includes matching the central device sending the scanning request according to the identification number of the peripheral device:
if the identification part of the scanning request is the same as the identification part in the received scanning request, the central equipment which sends the scanning request is judged to be target equipment, and the target equipment receives the broadcast information, the broadcast is closed, and the broadcasting is switched to sleep;
if the identification part is different from the identification part in the received scanning request, the central equipment which sends the scanning request is judged to be not the target equipment and the target equipment does not receive the broadcast information, the broadcast information is continuously sent, and the scanning request sent by the next central equipment is monitored and matched.
The present invention also provides a bluetooth system, comprising a central device and a peripheral device, wherein:
the central device is configured to store a central device identification number as an MAC address, where the central device identification number includes: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices; the system comprises a data processing module, a data processing module and a scanning module, wherein the data processing module is used for receiving broadcast information sent by peripheral equipment, caching the broadcast information and sending a scanning request; the method is used for analyzing the broadcast information according to a protocol, screening target peripheral equipment and extracting effective data in the target peripheral equipment after receiving the broadcast information sent by the peripheral equipment.
The peripheral device is configured to save a peripheral device identification number as a MAC address, where the peripheral device identification number includes: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices; the system comprises a central device, a scanning module, a data processing module and a data processing module, wherein the scanning module is used for sending broadcast information to the central device and monitoring a scanning request sent by the central device; the central equipment is used for analyzing the scanning request, screening target central equipment and entering dormancy according to the scanning request of the target central equipment after receiving the scanning request from the central equipment.
Preferably, the peripheral device identification number and the central device number include an identification part of two bytes and an ID part of four bytes.
Preferably, the center device is further configured to match the received broadcast information according to the identification number of the center device: if the identification part of the peripheral equipment is the same as the identification part in the received broadcast information, judging that the peripheral equipment sending the broadcast information is target equipment, and extracting effective data in the broadcast information for storage; if the identification part is different from the identification part in the received broadcast information, the peripheral equipment which sends the broadcast information is judged not to be the target equipment, and the broadcast information is abandoned.
Preferably, the peripheral device is further configured to match the central device that sends the scan request according to the peripheral device identification number: if the identification part of the scanning request is the same as the identification part in the received scanning request, judging that the central equipment sending the scanning request is target equipment and the target equipment receives the broadcast information, closing the broadcast and entering the dormancy; if the identification part is different from the identification part in the received scanning request, the central equipment which sends the scanning request is judged to be not the target equipment, and the target equipment does not receive the broadcast information, the broadcast information is continuously sent, and the scanning request sent by the next central equipment is monitored and matched.
Compared with the prior art, the technical scheme of the invention has the beneficial effects that:
1. the central equipment and the peripheral equipment are matched, and after the central equipment receives a large amount of broadcast information, the target peripheral equipment can be quickly screened out according to the identification part in the compared broadcast information, and the broadcast information which is not sent by the target peripheral equipment is abandoned, so that the workload of information extraction is reduced, more time is saved, and the communication efficiency is improved;
2. after the peripheral equipment receives the scanning request, whether the target central equipment has received the broadcast information or not can be judged according to the identification part in the comparison scanning request, when the matching is successful, the broadcast information is judged to be successfully received by the target central equipment, and at the moment, the broadcast is closed to enter the dormancy, so that the power consumption of the peripheral equipment is reduced;
3. after the peripheral equipment enters the dormancy, the wireless radio frequency signals in the air are reduced, the communication interference is reduced, the channel congestion is correspondingly slowed down, and the communication efficiency is improved; meanwhile, the peripheral equipment enters the dormancy state and does not send the broadcast information any more, so that the collection of repeated data can be reduced when the matched target central equipment receives the broadcast data, and the communication efficiency is further improved.
Drawings
Fig. 1 is a schematic diagram of a work flow of a center device in the bluetooth communication method of the present invention;
FIG. 2 is a schematic diagram of the working process of the peripheral device in the Bluetooth communication method of the present invention;
fig. 3 is a schematic diagram of the working process of the bluetooth system of the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The invention is further described below with reference to the accompanying drawings.
The embodiment of the invention provides a method for solving channel congestion and reducing power consumption caused by high concurrency of multiple devices in a low-power-consumption Bluetooth communication process, which is suitable for devices of a standard BLE protocol. According to the bluetooth core protocol, when the central device sends a scan request after receiving broadcast data from the peripheral device, the peripheral device sends a scan response after receiving the scan request, and the process does not exceed 10ms at most. Dividing the Bluetooth communication into a central device and a peripheral device in the specific working process of the Bluetooth communication, wherein the central device has a scanning function and can send a scanning request; the peripheral equipment has a broadcasting function, and replies to the central equipment after receiving the scanning request sent by the central equipment, wherein the replying process is a scanning response.
As shown in fig. 1, an embodiment of the present invention provides a bluetooth communication method, which is applied to a central device, and includes:
and setting a central equipment identification number and storing the identification number as the MAC address of the central equipment.
Wherein the center device identification number includes: an identification section for determining whether or not the devices are of the same group and an ID section for distinguishing different devices.
And receiving and caching the broadcast information sent by the peripheral equipment, and sending a scanning request.
It should be noted that, in a specific embodiment, the scan request includes a center device identification number, and the center device identification number is sent as a MAC address of the center device. When the central equipment receives the broadcast information and caches the broadcast information, the purpose of caching is to improve the data processing efficiency of the central equipment, because a large number of peripheral equipment possibly exists in the air, one central equipment can receive a large number of broadcast information and put the data into a special caching task list for processing, so that the pressure can be relieved, the abnormity caused by high concurrency is avoided, and the size of a caching queue can be reasonably set according to actual requirements.
After receiving the broadcast information sent by the peripheral equipment, analyzing the broadcast information according to a protocol, screening target peripheral equipment, and extracting effective data in the target peripheral equipment. Specifically, the target peripheral device indicates that the peripheral device and the central device are in the same group, and the broadcast information sent by the peripheral device is data that needs to be read by the central device.
And continuously receiving and processing the broadcast information sent by the next peripheral equipment.
It should be noted that, in a specific embodiment, parsing the broadcast information according to a protocol and screening target peripheral devices further includes matching the received broadcast information according to an identification number of the central device:
if the identification part of the peripheral equipment is the same as the identification part in the received broadcast information, judging that the peripheral equipment sending the broadcast information is target equipment, and extracting effective data in the broadcast information for storage;
if the identification part is different from the identification part in the received broadcast information, the peripheral equipment which sends the broadcast information is judged not to be the target equipment, and the broadcast information is abandoned.
In a preferred embodiment, the hub device identification number comprises an identification portion of two bytes and an ID portion of four bytes.
Specifically, the MAC address of BLE has a total length of 6 bytes, and these 6 bytes are divided into an identification part and an ID part. The 2-byte identification part is used for analyzing and judging whether the received broadcast information is sent by the target device or not for the central device, the ID part is used for distinguishing different devices, namely the ID part can be from 0x00000000 to 0 xfffffffffff in hexadecimal, and according to the limitation of a random MAC address in a Bluetooth core protocol, the random MAC address can not be all 0 or all 1, one group can contain 0 xffffffffd devices, and various use scenes can be met.
When matching is carried out, the central equipment and the peripheral equipment with the same identification parts are judged to be the same group, data interaction can be carried out only between the central equipment and the peripheral equipment of the same group, and after the central equipment receives a large amount of broadcast information, the target peripheral equipment can be quickly screened out according to the identification parts in the compared broadcast information, and the broadcast information which is not sent by the target peripheral equipment is abandoned, so that the workload of information extraction is reduced.
Specifically, when the central device receives the broadcast information sent by the peripheral device, the first two bytes of the MAC address are first matched: if the current two bytes are the same, judging that the peripheral equipment sending the broadcast information and the central equipment are the same group of equipment; when the current two bytes are different, it is determined that the peripheral device and the central device which send the broadcast information are not devices in the same group, and the central device directly discards the broadcast information when processing data. Therefore, when a large number of peripheral devices are arranged near the central device, data of different devices in the same group are discarded quickly, more time can be saved, and the data processing efficiency is improved.
It should be noted that, in other embodiments, the scan parameters of the central device may be configured according to actual situations, where the scan parameters refer to a scan gap and a scan window, and the scan window may affect power consumption. It should be noted that the scan window cannot be larger than the scan gap.
As shown in fig. 2, an embodiment of the present invention further provides a bluetooth communication method, applied to a peripheral device, including:
the peripheral device identification number is set and saved as its MAC address.
Wherein the peripheral device identification number includes: an identification section for determining whether or not the devices are of the same group and an ID section for distinguishing different devices.
Sending broadcast information to the central equipment, and monitoring a scanning request sent by the central equipment;
it should be noted that, in a specific embodiment, the broadcast information includes a peripheral device identification number, and the peripheral device identification number is sent as a MAC address of the peripheral device, and the peripheral device identification number includes: an identification section for determining whether or not the devices are of the same group and an ID section for distinguishing different devices.
After receiving a scanning request from the central equipment, analyzing the scanning request, screening target central equipment, and entering dormancy according to the scanning request of the target central equipment.
It should be noted that, in a specific embodiment, analyzing the scan request and screening the target central device further includes matching, according to the identification number of the peripheral device, the central device that sends the scan request:
if the identification part of the scanning request is the same as the identification part in the received scanning request, judging that the central equipment sending the scanning request is target equipment and the target equipment receives the broadcast information, closing the broadcast and entering the dormancy;
if the identification part is different from the identification part in the received scanning request, the central equipment which sends the scanning request is judged to be not the target equipment, and the target equipment does not receive the broadcast information, and then the broadcast information is continuously sent, and the scanning request sent by the next central equipment is monitored and matched.
In a preferred embodiment, the peripheral identification number comprises an identification portion of two bytes and an ID portion of four bytes.
Specifically, the total length of the MAC address of BLE is 6 bytes, and these 6 bytes are divided into an identification part and an ID part. The 2-byte identification part is used for analyzing and judging whether the received scanning request is sent by a target device or not for the peripheral device, the ID part is used for distinguishing different devices, namely the ID part can be from 0x00000000 to 0 xfffffffffff in hexadecimal, and according to the limitation of a random MAC address in a Bluetooth core protocol, the random MAC address can not be all 0 or all 1, one group can contain 0 xffffffffd devices, and various use scenes can be met.
When matching is carried out, the central equipment and the peripheral equipment with the same identification part are judged to be the same group, data interaction can be carried out only between the central equipment and the peripheral equipment in the same group, after the peripheral equipment receives a scanning request, whether the target central equipment receives the broadcast information or not can be judged according to the identification part in the comparison scanning request, when the matching is successful, the broadcast information is judged to be successfully received by the target central equipment, at the moment, the broadcast is closed, the sleep is carried out, and the power consumption of the peripheral equipment is reduced; at the moment, the wireless radio frequency signals in the air are reduced, the communication interference is reduced, the channel congestion is correspondingly relieved, and the communication efficiency is improved; meanwhile, the peripheral equipment enters the dormancy state and does not send the broadcast information any more, so that when the matched target central equipment receives the broadcast data, the collection of repeated data can be reduced, and the communication efficiency is further improved.
In a preferred embodiment, before transmitting the broadcast information, the method further comprises: and constructing a data packet according to a communication protocol, configuring broadcast parameters, updating data in the data packet into broadcast information, and starting a broadcast function.
In a preferred embodiment, after the peripheral device goes to sleep, the method further includes: and when new data information is acquired, sending an interrupt signal to peripheral equipment to wake up the peripheral equipment for data transmission. In another preferred embodiment, after the peripheral device goes to sleep, the method further includes: and waking up the peripheral equipment at regular time according to a preset time period so as to transmit data.
Specifically, the wake-up mechanism after the peripheral device goes to sleep may be various. In the embodiment of the present invention, the peripheral device may be awakened in any one of the following manners: 1. the time period is used for waking up, such as sending data in a timing mode for communication; 2. the sensor sets interrupt awakening, for example, after the sensor acquires data, an interrupt signal is given to the peripheral equipment to awaken the equipment for data transmission.
An embodiment of the present invention further provides a bluetooth system, which includes a central device and a peripheral device, as shown in fig. 3,
the central device is configured to save a central device identification number as an MAC address, where the central device identification number includes: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices; the system comprises a data processing module, a data processing module and a data processing module, wherein the data processing module is used for receiving broadcast information sent by peripheral equipment, caching the broadcast information and sending a scanning request; the method is used for analyzing the broadcast information according to a protocol, screening target peripheral equipment and extracting effective data in the target peripheral equipment after receiving the broadcast information sent by the peripheral equipment.
The peripheral device is configured to save a peripheral device identification number as a MAC address, where the peripheral device identification number includes: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices; the system is used for sending broadcast information to the central equipment and monitoring a scanning request sent by the central equipment; the central equipment is used for analyzing the scanning request, screening target central equipment and entering dormancy according to the scanning request of the target central equipment after receiving the scanning request from the central equipment.
It should be noted that the center device is further configured to match the received broadcast information according to the identification number of the center device: if the identification part of the peripheral equipment is the same as the identification part in the received broadcast information, judging that the peripheral equipment sending the broadcast information is target equipment, and extracting effective data in the broadcast information for storage; if the identification part is different from the identification part in the received broadcast information, the peripheral equipment which sends the broadcast information is judged not to be the target equipment, and the broadcast information is abandoned.
It should be noted that the peripheral device is further configured to match the central device that sends the scan request according to the peripheral device identification number: if the identification part of the scanning request is the same as the identification part in the received scanning request, the central equipment which sends the scanning request is judged to be target equipment, and the target equipment receives the broadcast information, the broadcast is closed, and the broadcasting is switched to sleep; if the identification part is different from the identification part in the received scanning request, the central equipment which sends the scanning request is judged to be not the target equipment, and the target equipment does not receive the broadcast information, and then the broadcast information is continuously sent, and the scanning request sent by the next central equipment is monitored and matched.
In a preferred embodiment, the peripheral device identification number and the central device number comprise an identification portion of two bytes and an ID portion of four bytes.
In a specific embodiment, the central device identification numbers of the central devices A1 and A2 are preset, and the peripheral device identification numbers of the peripheral devices B1, C1, and D1 are preset, so as to obtain the corresponding MAC addresses as follows:
the MAC address of the center device A1 is: 11 22 A1 A2 A3 A4;
the MAC address of the center device A2 is: 33 44 12 34 56;
the MAC address of the peripheral device B1 is: 11 22 B1 B2 B3 B4;
the MAC address of the peripheral device C1 is: 11 22 C1 C2 C3 C4;
the peripheral device D1, whose MAC address is: AA BB D1D 2D 3D 4.
After receiving the broadcast information of the peripheral devices B1, C1, and D1, the central device A1 first matches the first two bytes of the MAC address, and it can be seen that only the first two bytes of the MAC addresses of the devices B1 and C1 are the same as A1, so it is determined that A1, B1, and C1 are devices in the same group; if the first two bytes of the MAC addresses of D1 and A1 are different, it is determined that the two bytes are not the same group of devices, and the central device A1 directly discards the broadcast information of D1 and processes only the broadcast information of B1 and C1 when processing data. Therefore, when a large number of peripheral devices are arranged near the central device A1, the data of different groups are discarded quickly, more time can be saved, and the data processing efficiency is improved. Similarly, after the central device A2 receives the broadcast information of the peripheral devices B1, C1, and D1, the first two bytes of the MAC address are matched first, and since the first two bytes of the MAC address of the peripheral devices A2 and the first two bytes of the MAC address of the peripheral devices are different, it is determined that the peripheral devices are not the same group of devices, and the central device A2 directly discards the broadcast information of the peripheral devices B1, C1, and D1 when processing data.
When the peripheral device B1 receives the scan request from the center devices A1 and A2, the first two bytes of the MAC address of A2 are different from those of B1, so A2 and B1 are different groups, and B1 continues broadcasting. When the peripheral device B1 receives the scan request of A1, the first two bytes of the MAC addresses of A1 and B1 are the same, and it is determined that both are devices of the same group, so at this time, B1 considers that its data has been successfully received by the central device A1, and at this time, turns off the broadcast, and enters a low power consumption mode. At this time, the wireless radio frequency signals in the air are reduced, the communication interference is reduced, channel congestion can be correspondingly relieved, and the communication efficiency is improved. The other peripheral devices work the same way.
It should be understood that the above is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all equivalent structures or equivalent flow transformations made by the present specification and drawings, or applied directly or indirectly to other related technical fields, are included in the scope of the present invention.

Claims (8)

1. A Bluetooth communication method is applied to a center device and comprises the following steps:
setting a central equipment identification number and storing the central equipment identification number as an MAC address of the central equipment; wherein the center device identification number includes: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices;
receiving and caching broadcast information sent by peripheral equipment, and sending a scanning request; the scanning request comprises a central equipment identification number, the central equipment identification number is stored as an MAC address of the central equipment and comprises an identification part for judging whether the central equipment is the same group of equipment and an ID part for distinguishing different equipment;
after receiving broadcast information sent by peripheral equipment, analyzing the broadcast information, screening target peripheral equipment, and extracting effective data in the target peripheral equipment;
continuously receiving and processing the broadcast information sent by the next peripheral equipment;
the bluetooth communication method further comprises, applied to the peripheral device:
setting a peripheral equipment identification number, and storing the peripheral equipment identification number as an MAC address of the peripheral equipment identification number, wherein the peripheral equipment identification number comprises: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices;
sending broadcast information to the central equipment, and monitoring a scanning request sent by the central equipment;
after receiving a scanning request from the central equipment, analyzing the scanning request, screening target central equipment, and entering a sleep state according to the scanning request of the target central equipment:
if the identification part of the scanning request is the same as the identification part in the received scanning request, judging that the central equipment sending the scanning request is target equipment and the target equipment receives the broadcast information, closing the broadcast and entering the dormancy;
if the identification part is different from the identification part in the received scanning request, the central equipment which sends the scanning request is judged to be not the target equipment and the target equipment does not receive the broadcast information, the broadcast information is continuously sent, and the scanning request sent by the next central equipment is monitored and matched.
2. The bluetooth communication method according to claim 1, wherein the center apparatus identification number includes an identification part of two bytes and an ID part of four bytes.
3. The bluetooth communication method according to claim 1, wherein the broadcast information includes a peripheral device identification number, the peripheral device identification number being held as a MAC address of the peripheral device, which includes an identification part for determining whether it is the same group of devices and an ID part for distinguishing different devices.
4. The bluetooth communication method according to claim 3, wherein parsing the broadcast information and filtering the target peripheral device further comprises matching the received broadcast information according to the identification number of the center device:
if the identification part of the peripheral equipment is the same as the identification part in the received broadcast information, judging that the peripheral equipment sending the broadcast information is target equipment, and extracting effective data in the broadcast information for storage;
if the identification part is different from the identification part in the received broadcast information, the peripheral equipment which sends the broadcast information is judged not to be the target equipment, and the broadcast information is abandoned.
5. The bluetooth communication method according to claim 1, wherein the peripheral device identification number includes an identification part of two bytes and an ID part of four bytes.
6. A Bluetooth communication system comprising a center device and a peripheral device, characterized in that,
the central device is configured to save a central device identification number as an MAC address, where the central device identification number includes: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices; the system comprises a data processing module, a data processing module and a data processing module, wherein the data processing module is used for receiving broadcast information sent by peripheral equipment, caching the broadcast information and sending a scanning request; the system comprises a network side, a network side and a network side, wherein the network side is used for receiving broadcast information sent by peripheral equipment, analyzing the broadcast information according to a protocol, screening target peripheral equipment and extracting effective data in the target peripheral equipment after receiving the broadcast information sent by the peripheral equipment; the peripheral device is configured to save a peripheral device identification number as a MAC address, where the peripheral device identification number includes: an identification section for judging whether or not the devices are of the same group and an ID section for distinguishing different devices; the system is used for sending broadcast information to the central equipment and monitoring a scanning request sent by the central equipment; the central equipment is used for analyzing the scanning request, screening target central equipment and entering dormancy according to the scanning request of the target central equipment after receiving the scanning request from the central equipment;
the peripheral equipment is also used for matching the central equipment sending the scanning request according to the peripheral equipment identification number: if the identification part of the scanning request is the same as the identification part in the received scanning request, the central equipment which sends the scanning request is judged to be target equipment, and the target equipment receives the broadcast information, the broadcast is closed, and the broadcasting is switched to sleep; if the identification part is different from the identification part in the received scanning request, the central equipment which sends the scanning request is judged to be not the target equipment, and the target equipment does not receive the broadcast information, and then the broadcast information is continuously sent, and the scanning request sent by the next central equipment is monitored and matched.
7. The bluetooth communication system according to claim 6, wherein the peripheral device identification number and the center device number include an identification part of two bytes and an ID part of four bytes.
8. The bluetooth communication system according to claim 6, wherein the center device is further configured to match the received broadcast information according to the identification number of the center device: if the identification part of the peripheral equipment is the same as the identification part in the received broadcast information, judging that the peripheral equipment sending the broadcast information is target equipment, and extracting effective data in the broadcast information for storage; if the identification part is different from the identification part in the received broadcast information, the peripheral equipment which sends the broadcast information is judged not to be the target equipment, and the broadcast information is abandoned.
CN202211270984.6A 2022-10-18 2022-10-18 Bluetooth communication method and Bluetooth system Active CN115334486B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211270984.6A CN115334486B (en) 2022-10-18 2022-10-18 Bluetooth communication method and Bluetooth system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211270984.6A CN115334486B (en) 2022-10-18 2022-10-18 Bluetooth communication method and Bluetooth system

Publications (2)

Publication Number Publication Date
CN115334486A CN115334486A (en) 2022-11-11
CN115334486B true CN115334486B (en) 2023-03-03

Family

ID=83915275

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211270984.6A Active CN115334486B (en) 2022-10-18 2022-10-18 Bluetooth communication method and Bluetooth system

Country Status (1)

Country Link
CN (1) CN115334486B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116828435B (en) * 2023-08-30 2023-11-14 北京柚果星空科技有限公司 Equipment forwarding method and system of soft Bluetooth gateway

Citations (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1691603A (en) * 2004-04-28 2005-11-02 联想(北京)有限公司 A method for implementing equipment group and intercommunication between grouped equipments
CN101222346A (en) * 2008-01-22 2008-07-16 张建中 Method, apparatus and system for single-source multicast interaction and multi-source multicast interaction
WO2015069031A1 (en) * 2013-11-06 2015-05-14 엘지전자(주) Method and apparatus for forming communication link using bluetooth
CN105338659A (en) * 2015-11-27 2016-02-17 深圳市朗科科技股份有限公司 Device connection method and terminal
CN106375934A (en) * 2015-07-24 2017-02-01 马维尔国际有限公司 A wireless communication method and terminal based on bluetooth low-power consumption techniques and user equipment
CN106686535A (en) * 2017-01-23 2017-05-17 飞天诚信科技股份有限公司 Method and device for achieving low-power Bluetooth communication on IOS (iphone operation system)
CN107197424A (en) * 2017-06-06 2017-09-22 欧普照明股份有限公司 Bluetooth connecting method, bluetooth equipment and bluetooth connection system
WO2018125989A2 (en) * 2016-12-30 2018-07-05 Intel Corporation The internet of things
CN110191447A (en) * 2019-05-28 2019-08-30 深圳云里物里科技股份有限公司 The filter method and relevant apparatus of Bluetooth broadcast packet in a kind of ESL
WO2020063228A1 (en) * 2018-09-26 2020-04-02 维沃移动通信有限公司 Signal sending method and receiving method and sending device and receiving device
EP3672358A1 (en) * 2018-12-20 2020-06-24 Baintex Technologies, S.L. Method of communication through ble protocol in broadcast and filtered by mac
CN111436038A (en) * 2019-10-23 2020-07-21 珠海市杰理科技股份有限公司 Bluetooth connection method and system, Bluetooth master and slave device connection method and Bluetooth master and slave device
CN111885562A (en) * 2020-07-01 2020-11-03 精伦电子股份有限公司 Bluetooth networking method and system
CN112203263A (en) * 2020-09-25 2021-01-08 深圳市晨北科技有限公司 Broadcast message interaction method, terminal, device and medium
CN115150795A (en) * 2021-03-30 2022-10-04 中国移动通信有限公司研究院 Information filtering method, bluetooth antenna and Internet of things data platform

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CA2969065A1 (en) * 2014-11-25 2016-06-02 Loud-Hailer, Inc. Local and temporal method and system of broadcasting via peer-to-peer network
CN106304046B (en) * 2015-06-01 2020-01-07 陈晓华 Method for encrypting and authenticating iBeacon broadcast message
CN106255087B (en) * 2016-09-09 2022-01-04 北京远度互联科技有限公司 Networking method and device
CN106936929A (en) * 2017-04-21 2017-07-07 深圳华制智能制造技术有限公司 A kind of things-internet gateway equipment, internet of things equipment group network system and its network-building method
CN107493563B (en) * 2017-08-31 2020-10-27 大唐终端技术有限公司 Method and system for realizing group talkback by Bluetooth
CN108347807A (en) * 2017-12-07 2018-07-31 中山市新邦照明电器有限公司 Illumination control method and lamps and lanterns
CN109168214A (en) * 2018-08-31 2019-01-08 四川蓝景光电技术有限责任公司 LED lamp control method and system, LED control gateway
CN113271579B (en) * 2021-05-24 2022-10-11 杭州涂鸦信息技术有限公司 Bluetooth device control method, client, computer device and readable storage medium
CN114120609B (en) * 2021-10-27 2023-11-14 深圳市芯中芯科技有限公司 Remote controller pairing, binding and pairing system and method based on Bluetooth broadcasting

Patent Citations (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1691603A (en) * 2004-04-28 2005-11-02 联想(北京)有限公司 A method for implementing equipment group and intercommunication between grouped equipments
CN101222346A (en) * 2008-01-22 2008-07-16 张建中 Method, apparatus and system for single-source multicast interaction and multi-source multicast interaction
WO2015069031A1 (en) * 2013-11-06 2015-05-14 엘지전자(주) Method and apparatus for forming communication link using bluetooth
CN106375934A (en) * 2015-07-24 2017-02-01 马维尔国际有限公司 A wireless communication method and terminal based on bluetooth low-power consumption techniques and user equipment
CN105338659A (en) * 2015-11-27 2016-02-17 深圳市朗科科技股份有限公司 Device connection method and terminal
WO2018125989A2 (en) * 2016-12-30 2018-07-05 Intel Corporation The internet of things
CN106686535A (en) * 2017-01-23 2017-05-17 飞天诚信科技股份有限公司 Method and device for achieving low-power Bluetooth communication on IOS (iphone operation system)
CN107197424A (en) * 2017-06-06 2017-09-22 欧普照明股份有限公司 Bluetooth connecting method, bluetooth equipment and bluetooth connection system
WO2020063228A1 (en) * 2018-09-26 2020-04-02 维沃移动通信有限公司 Signal sending method and receiving method and sending device and receiving device
EP3672358A1 (en) * 2018-12-20 2020-06-24 Baintex Technologies, S.L. Method of communication through ble protocol in broadcast and filtered by mac
CN110191447A (en) * 2019-05-28 2019-08-30 深圳云里物里科技股份有限公司 The filter method and relevant apparatus of Bluetooth broadcast packet in a kind of ESL
CN111436038A (en) * 2019-10-23 2020-07-21 珠海市杰理科技股份有限公司 Bluetooth connection method and system, Bluetooth master and slave device connection method and Bluetooth master and slave device
CN111885562A (en) * 2020-07-01 2020-11-03 精伦电子股份有限公司 Bluetooth networking method and system
CN112203263A (en) * 2020-09-25 2021-01-08 深圳市晨北科技有限公司 Broadcast message interaction method, terminal, device and medium
CN115150795A (en) * 2021-03-30 2022-10-04 中国移动通信有限公司研究院 Information filtering method, bluetooth antenna and Internet of things data platform

Also Published As

Publication number Publication date
CN115334486A (en) 2022-11-11

Similar Documents

Publication Publication Date Title
CN108738109B (en) Site awakening method and site
CN113613316B (en) Indication method and device of downlink service data
CN113630852B (en) Data communication method and device
US8879453B2 (en) Infrastructure offload wake on wireless LAN (WOWL)
CN107979443B (en) Wake-up method and device
CN1835496B (en) Communication apparatus and method of controlling same
CN109314923B (en) Site awakening method, related equipment and system
US20100189021A1 (en) Method and apparatus for power management in wlan
KR20150121168A (en) Polling beacon
CN115334486B (en) Bluetooth communication method and Bluetooth system
US10856228B1 (en) Systems and methods for transmitting a wake-up request frame to lower power devices in a wireless network
KR20100095524A (en) Method and apparatus for power management in communication system
EP3881521B1 (en) Prioritized low power neighboring node discovery in an iot network
CN107820305B (en) Method and device for transmitting WUR message
CN111586814A (en) Low-power consumption processing method, device, equipment and storage medium for wireless network terminal node
US20190215771A1 (en) Beacon signal processing system and filtering method of reducing wake-up frequency
CN110062447A (en) A method of reducing wireless self-organization network downstream response time delay
US10772041B2 (en) Beacon signal processing system
CN108012315B (en) Communication method, network equipment and terminal
CN101998597A (en) Broadcast message sending indication method, receiving method and device and system thereof
KR101578928B1 (en) Method to control Sleep Mode Terminal and Apparatus Thereof
CN109495796B (en) Remote radio terminal control method and concentrator
WO2021261046A1 (en) Communication device, communication program, and communication method
CN108632959B (en) Site awakening method and target site
TWI784657B (en) Method for receiving wireless data and wireless equipment

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