CN112105009A - Device discovery and Bluetooth broadcasting method, device, electronic device and storage medium - Google Patents
Device discovery and Bluetooth broadcasting method, device, electronic device and storage medium Download PDFInfo
- Publication number
- CN112105009A CN112105009A CN202010910743.8A CN202010910743A CN112105009A CN 112105009 A CN112105009 A CN 112105009A CN 202010910743 A CN202010910743 A CN 202010910743A CN 112105009 A CN112105009 A CN 112105009A
- Authority
- CN
- China
- Prior art keywords
- bluetooth
- identification field
- equipment
- information
- broadcast
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 51
- 238000013507 mapping Methods 0.000 claims abstract description 57
- 230000006870 function Effects 0.000 claims description 17
- 238000004590 computer program Methods 0.000 claims description 5
- 238000004891 communication Methods 0.000 abstract description 2
- 230000008569 process Effects 0.000 description 4
- 238000010586 diagram Methods 0.000 description 3
- 238000013461 design Methods 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000002093 peripheral effect Effects 0.000 description 2
- 206010063385 Intellectualisation Diseases 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000012423 maintenance Methods 0.000 description 1
- 230000006855 networking Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000012545 processing Methods 0.000 description 1
- 230000001960 triggered effect Effects 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W4/00—Services specially adapted for wireless communication networks; Facilities therefor
- H04W4/80—Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W8/00—Network data management
- H04W8/005—Discovery of network devices, e.g. terminals
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Databases & Information Systems (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
The embodiment of the invention relates to the technical field of communication, and discloses a device discovery and Bluetooth broadcasting method, a device, electronic equipment and a storage medium. The equipment discovery method comprises the following steps: scanning a Bluetooth device broadcast to acquire an identification field in the broadcast; if the identification field is set according to a preset rule, searching the equipment detailed information matched with the acquired identification field according to the mapping relation between the pre-stored identification field and the equipment detailed information of the Bluetooth equipment; and when a Bluetooth equipment display instruction is received, displaying the detailed equipment information on the Bluetooth equipment display interface. Through the technical means, the terminal equipment can acquire and display the detailed equipment information of the Bluetooth equipment only through the identification information with less data volume in the broadcast of the Bluetooth equipment, so that more equipment information can not be leaked in the broadcast of the Bluetooth equipment, and the data security of the Bluetooth equipment is improved.
Description
Technical Field
The embodiment of the invention relates to the technical field of communication, in particular to a device discovery and Bluetooth broadcasting method, a device, an electronic device and a storage medium.
Background
With the development of science and technology, intelligent devices are applied more and more in our lives. Particularly in the field of intelligent home furnishing, different intelligent home furnishing devices enable the life of people to gradually go from automation to an intelligent stage, and more convenience is provided for our life. In the intelligent home field, when a user uses a certain intelligent device for the first time, the device is bound with the corresponding intelligent home platform, so that the related functions of the extended device can be better, and better intellectualization is realized. This binding function often needs to be done by means of an application in the terminal device, e.g. a mobile phone. Currently, for most intelligent devices, a bluetooth function is generally adopted to connect and interact with a terminal device. For an intelligent device with a bluetooth function, related data detection is currently implemented through broadcasting of a GAP layer.
However, the inventors of the present invention found that: currently, in the broadcast messages of the bluetooth GAP layer, the device name is generally only carried in the broadcast messages, and the terminal device only displays the name information scanned in the bluetooth broadcast. If more device information is to be displayed, the bluetooth device needs to put more data in the broadcast. However, the broadcast message size specified in the current bluetooth protocol is limited, and particularly, the message size specified in the bluetooth low energy BLE4.0 specification is only 31 bytes, so that it is difficult for the terminal device to acquire detailed device information of the bluetooth device through broadcasting.
Disclosure of Invention
Embodiments of the present invention provide a device discovery and bluetooth broadcasting method, apparatus, electronic device, and storage medium, so that a terminal device can obtain and display detailed device information of a bluetooth device only through identification information with a small data amount in a bluetooth device broadcast.
In order to solve the above technical problem, an embodiment of the present invention provides an apparatus discovery method, including: scanning a Bluetooth device broadcast to acquire an identification field in the broadcast; if the identification field is set according to a preset rule, searching the equipment detailed information matched with the acquired identification field according to the mapping relation between the pre-stored identification field and the equipment detailed information of the Bluetooth equipment; and when a Bluetooth equipment display instruction is received, displaying the detailed equipment information on a Bluetooth equipment display interface.
The embodiment of the invention also provides a Bluetooth broadcasting method, which comprises the following steps: setting an identification field in the Bluetooth broadcast information according to a preset rule; wherein, include at least in the bluetooth broadcast information: a basic device description; the identification field is used for searching the detailed equipment information matched with the identification field in the mapping relation between the pre-stored identification field and the Bluetooth equipment; and starting the discovered state of the Bluetooth device and broadcasting Bluetooth broadcast information.
An embodiment of the present invention further provides an apparatus for discovering devices, including: the Bluetooth scanning module is used for scanning the broadcast of the Bluetooth equipment and acquiring an identification field in the broadcast; the information searching module is used for searching the device detailed information matched with the acquired identification field according to the mapping relation between the pre-stored identification field and the device detailed information of the Bluetooth device when the identification field is the identification field set according to the preset rule; and the information display module is used for displaying the detailed information of the equipment on the Bluetooth equipment display interface when receiving the Bluetooth equipment display instruction.
An embodiment of the present invention further provides a bluetooth broadcasting apparatus, including: the identification generation module is used for setting an identification field in the Bluetooth broadcast information according to a preset rule; wherein, include at least in the bluetooth broadcast information: a basic device description; the identification field is used for searching the device detailed information matched with the identification field in the mapping relation between the pre-stored identification field and the device detailed information of the Bluetooth device; and the Bluetooth function module is used for starting the discovered state of the Bluetooth equipment and broadcasting Bluetooth broadcast information.
An embodiment of the present invention further provides an electronic device, including: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the device discovery method as described above or to perform the bluetooth broadcast method as described above.
Embodiments of the present invention also provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements a device discovery method as described above or performs a bluetooth broadcast method as described above.
Compared with the prior art, the method and the device for displaying the Bluetooth device data have the advantages that the specific identification field is identified from the broadcast when the terminal device scans the Bluetooth broadcast, the detailed device information of the Bluetooth device is searched and displayed according to the identification field, the terminal device can acquire and display the detailed device information of the Bluetooth device only through the identification information with small data volume in the broadcast of the Bluetooth device, the Bluetooth device is prevented from leaking more device information in the broadcast, and the data safety of the Bluetooth device is improved.
In addition, in this embodiment, before scanning the broadcast of the surrounding bluetooth devices, the method further includes: acquiring a mapping relation from a background server, and storing the acquired mapping relation in a local cache database; according to the mapping relation between the pre-stored identification field and the device detailed information of the Bluetooth device, searching the device detailed information matched with the acquired identification field, wherein the method comprises the following steps: and searching the detailed equipment information matched with the acquired identification field in the mapping relation stored in the local cache database. Through storing a large amount of detailed equipment information in the background server in advance, when carrying out bluetooth scanning, can show abundanter equipment information, expand follow-up operating space to bluetooth equipment.
In addition, in this embodiment, according to a mapping relationship between the pre-stored identification field and the device detailed information of the bluetooth device, finding the device detailed information matched with the acquired identification field further includes: if the detailed equipment information matched with the acquired identification field is not found in the mapping relation stored in the local cache database, acquiring a new mapping relation from the background server; and searching the detailed information of the equipment matched with the acquired identification field in the new mapping relation. When Bluetooth scanning is carried out, detailed device information corresponding to the device is searched locally, and when the detailed device information does not exist locally, updating is carried out from the background server, so that the latest device detailed information can be obtained in real time under the networking condition, and the speed of searching the device detailed information can be preferentially ensured.
In addition, before the displaying the detailed device information on the bluetooth device display interface, the method further includes: calculating the distance between the Bluetooth equipment and the terminal equipment according to the broadcasting of the Bluetooth equipment; and displaying the Bluetooth devices with the distances meeting the preset conditions in the first device list and the second device list. After carrying out bluetooth broadcast scanning, come to filter the bluetooth equipment that shows through the distance of broadcast computing equipment, only show the higher bluetooth equipment of signal strength, improve the operation experience of user when carrying out the bluetooth connection.
Drawings
One or more embodiments are illustrated by the corresponding figures in the drawings, which are not meant to be limiting.
Fig. 1 is a flow chart of a device discovery method according to a first embodiment of the present invention;
fig. 2 is a flow chart of a device discovery method according to a second embodiment of the present invention;
fig. 3 is a flowchart of a bluetooth broadcasting method according to a third embodiment of the present invention;
fig. 4 is a schematic structural diagram of a device discovery apparatus according to a fourth embodiment of the present invention;
fig. 5 is a schematic structural diagram of a bluetooth broadcasting apparatus according to a fifth embodiment of the present invention;
fig. 6 is a schematic structural diagram of an electronic device according to a sixth embodiment of the invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the embodiments of the present invention will be described in detail with reference to the accompanying drawings. However, it will be appreciated by those of ordinary skill in the art that in various embodiments of the invention, numerous technical details are set forth in order to provide a better understanding of the present application. However, the technical solution claimed in the present application can be implemented without these technical details and various changes and modifications based on the following embodiments. The following embodiments are divided for convenience of description, and should not constitute any limitation to the specific implementation manner of the present invention, and the embodiments may be mutually incorporated and referred to without contradiction.
A first embodiment of the present invention relates to a device discovery method. The specific process is shown in fig. 1, and comprises the following steps: scanning a Bluetooth device broadcast to acquire an identification field in the broadcast; if the identification field is set according to a preset rule, searching the equipment detailed information matched with the acquired identification field according to the mapping relation between the pre-stored identification field and the equipment detailed information of the Bluetooth equipment; and when a Bluetooth equipment display instruction is received, displaying the detailed equipment information on the Bluetooth equipment display interface. In this embodiment, an execution main body of the device discovery method is a terminal device, for example, an intelligent terminal device with a bluetooth function, such as a mobile phone, a computer, and a tablet computer.
The following describes in detail the implementation details of the device discovery method in this embodiment, and the following is only provided for the convenience of understanding and is not necessary for implementing this embodiment.
The device discovery method in this embodiment is shown in fig. 1, and specifically includes:
Specifically, in the related art, the smart home devices generally employ a bluetooth function to connect with the terminal device. When a user manages the Bluetooth equipment through the terminal equipment, namely the intelligent household equipment with the Bluetooth function is adopted, the Bluetooth equipment existing around is scanned through the Bluetooth function of the terminal equipment, and the equipment identity is identified through the identification field carried in the broadcast information of the Bluetooth equipment.
Specifically, for the bluetooth function of the device itself, only basic information of the bluetooth device, such as a device ID and a device address, in the broadcast information is generally identified, and other information is often acquired by connecting transmitted data after the bluetooth connection is established. Limited by the limitation of the data length of the broadcast information, the terminal device cannot acquire detailed information about the bluetooth device from the broadcast information of the bluetooth device. In this embodiment, the bluetooth function is called through the device management application program in the terminal device, and the device management application program can read the bluetooth device broadcast scanned by the bluetooth function, and further read a certain identification field in the broadcast information. When the bluetooth device leaves the factory, a manufacturer of the device management application program may agree with a device manufacturer for identification rules, an identification field in the broadcast information of the bluetooth device may be set according to the pre-agreed rules, and bluetooth devices of different manufacturers often adopt different identification rules.
Further, the device management application program often identifies bluetooth devices of a single manufacturer or a plurality of manufacturers having a cooperative relationship, and the bluetooth devices set the identification field in the broadcast information according to the same preset rule.
And 103, searching the device detailed information matched with the acquired identification field according to the mapping relation between the pre-stored identification field and the device detailed information of the Bluetooth device.
And 104, when receiving the Bluetooth equipment display instruction, displaying equipment information on a Bluetooth equipment display interface.
Specifically, after scanning the bluetooth broadcast, the terminal device discovers the surrounding bluetooth devices, reads the identification field in the broadcast, and determines whether the identification field meets the specification of the preset rule through the device management application program. And when the identification field meets the regulation of a preset rule, searching the matched equipment detailed information in the mapping relation between the identification field stored in the application background and the equipment detailed information of the Bluetooth equipment according to the identification field. And when the identification field does not meet the regulation of the preset rule, the manufacturer of the Bluetooth device is not a product of the manufacturer which can be identified by the application program, and relevant basic device information carried in the Bluetooth broadcast of the device is displayed.
In one example, the device details stored by the application background may include: device name, device picture, device attribute, device function description, device interaction description, and the like.
In another example, the terminal device may present the user with a bluetooth device presentation interface that may include two parts, a first device list and a second device list. The first device list displays the discovered Bluetooth devices and related device detailed information; the second device list displays basic device descriptions carried in the device bluetooth broadcast, i.e., device IDs and device addresses. In addition, the terminal device may include more parts for displaying the bluetooth device display interface displayed by the user, and further display the device information in the original first device list in different sub-lists according to different manufacturers, so as to provide a more detailed device description for the user, and facilitate the user to manage the discovered bluetooth device.
In another example, the terminal device may further read the signal strength of the scanned bluetooth broadcast through the device management application before the bluetooth device displays the interface display device detailed information, so as to calculate the distance between the bluetooth device and the terminal device by receiving the signal strength RSSI, and only display the bluetooth devices whose distance satisfies the preset condition in the first device list and the second device list, thereby helping the user to eliminate the bluetooth devices with a longer distance, enabling the user not to be interfered by irrelevant device information when managing the device, and further improving the user experience.
It should be noted that the above examples in the present embodiment are only for easy understanding, and do not limit the technical scheme of the present invention.
Compared with the prior art, the terminal device in the embodiment stores the identification field setting rule agreed with the Bluetooth device in advance through the application program, and the mapping relation between the identification field and the device detailed information, and searches and displays the device detailed information stored in the background when the identification field meeting the rule is identified in the broadcast, so that the terminal device can acquire and display the device detailed information of the Bluetooth device only through the identification information with less data volume in the broadcast of the Bluetooth device, thereby ensuring that the Bluetooth device does not leak more device information in the broadcast, and improving the safety of the data of the Bluetooth device.
A second embodiment of the present invention relates to a device discovery method. The second embodiment is substantially the same as the first embodiment, and the main difference is that in the second embodiment of the present invention, before scanning the surrounding bluetooth device broadcasts, the method further includes: acquiring a mapping relation from a background server, and storing the acquired mapping relation in a local cache database; according to the mapping relation between the pre-stored identification field and the device detailed information of the Bluetooth device, searching the device detailed information matched with the acquired identification field, wherein the method comprises the following steps: and searching the detailed equipment information matched with the acquired identification field in the mapping relation stored in the local cache database.
The following describes in detail the implementation details of the device discovery method in this embodiment, and the following is only provided for the convenience of understanding and is not necessary for implementing this embodiment.
The device discovery method in this embodiment is shown in fig. 2, and specifically includes:
Specifically, the mapping relationship between the identification field and the detailed device information is generated by an operator of the device management application program and stored in a background server at the cloud, when a user starts the device management application program on the terminal device, the mapping relationship between the identification field and the detailed device information is obtained by the background server, and the obtained mapping relationship is stored in a local cache database, so that the bluetooth device can be conveniently searched and called in the subsequent discovery process.
Further, when a bluetooth device manufacturer updates data of the bluetooth device or develops a new smart home device product, the relevant device detailed information is sent to an operator of the device management application program, and then the mapping relationship in the background server is updated.
Specifically, step 202 and step 203 are similar to step 101 and step 102 in the first embodiment of the present invention, and the difference is that in the first embodiment, when the determination result in step 102 is yes, step 103 is executed to search for the device detailed information matching the acquired identification field according to the mapping relationship between the pre-stored identification field and the detailed information of the bluetooth device; in the second embodiment, when the determination result in step 203 is yes, step 204 is executed to search whether the device detail information matching the acquired identification field exists in the local cache database. Other implementation details of step 202 and step 203 have been specifically described in the first embodiment, and are not described herein again.
If the device detail information matching with the acquired identification field is not found in the local cache database, step 205 is executed to acquire a new mapping relationship from the background server, and find the device detail information matching with the acquired identification field in the new mapping relationship.
Specifically, when the terminal device identifies an identification field meeting a preset rule in the scanned Bluetooth broadcast, the identification field is firstly searched in a local cache database, and due to local storage of data, the retrieval speed is high, and the matched detailed device information can be displayed in a Bluetooth device display interface immediately. Due to the consideration of reducing the consumption of system resources, the local cache database does not always synchronize the mapping relation to the background server in real time. Therefore, when the user does not actively update the local cache database, it may be found in the bluetooth scan that the identification field meeting the preset rule is included but the matching device detail information is not retrieved in the local cache database, at this time, the device management application program may be triggered to synchronize data with the background server, update the mapping relationship in the local cache database, and then search the updated local cache database for the device detail information matching the identification field.
And step 206, when receiving the Bluetooth equipment display instruction, displaying the equipment information on the Bluetooth equipment display interface.
Step 206 is the same as step 104 in the first embodiment of the present invention, and details of the implementation have been specifically described in the first embodiment, and are not described herein again.
In this embodiment, the mapping relationship between the identification field and the detailed device information is maintained and updated by the cloud backend server, and when the terminal device needs the mapping relationship, the mapping relationship is updated to the backend server through the device management application program, so that a user can acquire the latest detailed device information when needed.
The steps of the above methods are divided for clarity, and the implementation may be combined into one step or split some steps, and the steps are divided into multiple steps, so long as the same logical relationship is included, which are all within the protection scope of the present patent; it is within the scope of the patent to add insignificant modifications to the algorithms or processes or to introduce insignificant design changes to the core design without changing the algorithms or processes.
A third embodiment of the present invention relates to a bluetooth broadcasting method, as shown in fig. 3, including:
Specifically, when the bluetooth device leaves the factory, the manufacturer of the device management application may agree with the device manufacturer for the identification rule, the identification field in the broadcast information of the bluetooth device may be set according to the pre-agreed rule, and the bluetooth devices of different manufacturers often use different rules to set the identification field in the broadcast information. The identification field is used for searching the device detailed information matched with the identification field in the mapping relationship between the pre-stored identification field and the device detailed information of the Bluetooth device, in addition, a Bluetooth device manufacturer can send the detailed information of the Bluetooth device to a manufacturer of the device management application program, and the manufacturer of the device management application program establishes the mapping relationship between the identification field and the device detailed information and carries out maintenance and updating.
Specifically, when the bluetooth device is put into use, the bluetooth device is continuously kept in a discovered state, and broadcasting information carrying an identification field set according to a preset rule is broadcasted.
It should be noted that the present embodiment is a method embodiment applied to a bluetooth device side corresponding to the first embodiment and the second embodiment, and the present embodiment can be implemented in cooperation with the first embodiment and the second embodiment. The related technical details mentioned in the first embodiment and the second embodiment are still valid in this embodiment, and are not described herein again to reduce repetition. Accordingly, the related technical details mentioned in the present embodiment can also be applied to the first embodiment and the second embodiment.
A fourth embodiment of the present invention relates to a device discovery apparatus, as shown in fig. 4, including:
the bluetooth scanning module 401 is configured to scan a bluetooth device broadcast and acquire an identifier field in the broadcast.
And the information searching module 402 is configured to search the device detailed information matched with the acquired identification field according to a mapping relationship between the pre-stored identification field and the device detailed information of the bluetooth device when the identification field is the identification field set according to the preset rule.
In an example, the information searching module 402 is further configured to obtain a mapping relationship from a background server, and store the obtained mapping relationship in a local cache database; and searching the detailed equipment information matched with the acquired identification field in the mapping relation stored in the local cache database.
In another example, the information searching module 402 is further configured to, when the device detail information matching the obtained identification field is not found in the mapping relationship stored in the local cache database, obtain a new mapping relationship from the background server, and search for the device detail information matching the obtained identification field in the new mapping relationship.
And an information display module 403, configured to display the detailed information of the device on a bluetooth device display interface when receiving the bluetooth device display instruction.
In an example, the information presentation module 403 is further configured to display the device detail information corresponding to the discovered bluetooth device in a first device list of the bluetooth device presentation interface; and displaying the basic device description corresponding to the discovered Bluetooth device in a second device list of the Bluetooth device display interface.
It should be understood that the present embodiment is a virtual device embodiment corresponding to the first and second embodiments, and the present embodiment can be implemented in cooperation with the first and second embodiments. The related technical details mentioned in the first embodiment and the second embodiment are still valid in this embodiment, and are not described herein again to reduce repetition. Accordingly, the related technical details mentioned in the present embodiment can also be applied to the first embodiment and the second embodiment.
It should be noted that, all the modules involved in this embodiment are logic modules, and in practical application, one logic unit may be one physical unit, may also be a part of one physical unit, and may also be implemented by a combination of multiple physical units. In addition, in order to highlight the innovative part of the present invention, a unit which is not so closely related to solve the technical problem proposed by the present invention is not introduced in the present embodiment, but this does not indicate that there is no other unit in the present embodiment.
A fifth embodiment of the present invention relates to a bluetooth broadcasting apparatus, as shown in fig. 5, including:
the identifier generating module 501 sets an identifier field in the bluetooth broadcast information according to a preset rule; wherein, the bluetooth broadcast information at least comprises: a basic device description; the identification field is used for searching the device detailed information matched with the identification field in the mapping relation between the pre-stored identification field and the device detailed information of the Bluetooth device;
a bluetooth function module 502, configured to start a bluetooth device discovered state, and broadcast the bluetooth broadcast information.
It should be understood that this embodiment is a virtual device embodiment corresponding to the third embodiment, and the embodiment can be implemented in cooperation with the third embodiment. The related technical details mentioned in the third embodiment are still valid in this embodiment, and are not described herein again in order to reduce repetition. Accordingly, the related-art details mentioned in the present embodiment can also be applied to the third embodiment.
It should be noted that, all the modules involved in this embodiment are logic modules, and in practical application, one logic unit may be one physical unit, may also be a part of one physical unit, and may also be implemented by a combination of multiple physical units. In addition, in order to highlight the innovative part of the present invention, a unit which is not so closely related to solve the technical problem proposed by the present invention is not introduced in the present embodiment, but this does not indicate that there is no other unit in the present embodiment.
A sixth embodiment of the present invention is directed to a server, as shown in fig. 6, including at least one processor 601; and a memory 602 communicatively coupled to the at least one processor 601; wherein the memory 602 stores instructions executable by the at least one processor 601, the instructions being executable by the at least one processor 601 to enable the at least one processor 601 to perform the device discovery method of the first embodiment or the second embodiment, or the bluetooth broadcast method of the third embodiment.
Where the memory 602 and the processor 601 are coupled by a bus, the bus may comprise any number of interconnected buses and bridges that couple one or more of the various circuits of the processor 601 and the memory 602 together. The bus may also connect various other circuits such as peripherals, voltage regulators, power management circuits, and the like, which are well known in the art, and therefore, will not be described any further herein. A bus interface provides an interface between the bus and the transceiver. The transceiver may be one element or a plurality of elements, such as a plurality of receivers and transmitters, providing a means for communicating with various other apparatus over a transmission medium. The data processed by the processor 601 is transmitted over a wireless medium via an antenna, which further receives the data and transmits the data to the processor 601. The processor 601 is responsible for managing the bus and general processing and may also provide various functions including timing, peripheral interfaces, voltage regulation, power management, and other control functions. While memory 602 may be used to store data used by processor 601 in performing operations.
A seventh embodiment of the present invention relates to a computer-readable storage medium storing a computer program. The computer program realizes the above-described method embodiments when executed by a processor.
That is, as can be understood by those skilled in the art, all or part of the steps in the method for implementing the embodiments described above may be implemented by a program instructing related hardware, where the program is stored in a storage medium and includes several instructions to enable a device (which may be a single chip, a chip, or the like) or a processor (processor) to execute all or part of the steps of the method described in the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
It will be understood by those of ordinary skill in the art that the foregoing embodiments are specific embodiments for practicing the invention, and that various changes in form and details may be made therein without departing from the spirit and scope of the invention in practice.
Claims (11)
1. A device discovery method, comprising:
scanning a Bluetooth device broadcast to acquire an identification field in the broadcast;
if the identification field is set according to a preset rule, searching the equipment detailed information matched with the acquired identification field according to the mapping relation between the pre-stored identification field and the equipment detailed information of the Bluetooth equipment;
and when a Bluetooth equipment display instruction is received, displaying the detailed equipment information on a Bluetooth equipment display interface.
2. The device discovery method of claim 1, further comprising, prior to said scanning for surrounding bluetooth device broadcasts:
acquiring the mapping relation from a background server, and storing the acquired mapping relation in a local cache database;
the searching for the device detailed information matched with the acquired identification field according to the mapping relation between the pre-stored identification field and the device detailed information of the bluetooth device comprises:
and searching the detailed equipment information matched with the acquired identification field in the mapping relation stored in the local cache database.
3. The device discovery method according to claim 2, wherein the searching for the device details matching the obtained identification field according to the mapping relationship between the pre-stored identification field and the device details of the bluetooth device further comprises:
if the detailed device information matched with the acquired identification field is not found in the mapping relation stored in the local cache database, acquiring a new mapping relation from the background server;
and searching the detailed equipment information matched with the acquired identification field in the new mapping relation.
4. The device discovery method of claim 1, wherein said bluetooth device presentation interface comprises: a first device list and a second device list; the first device list displays the device detailed information corresponding to the discovered Bluetooth device, and the second device list displays the basic device description corresponding to the discovered Bluetooth device;
after the acquiring the identification field in the broadcast, further comprising:
and if the identification field is not the identification field set according to the preset rule, displaying the basic equipment description carried in the broadcast in the second equipment list.
5. The device discovery method according to claim 4, further comprising, before said presenting said device details at said bluetooth device presentation interface:
calculating the distance between the Bluetooth equipment and the terminal equipment according to the broadcasting of the Bluetooth equipment;
and displaying the Bluetooth equipment with the distance meeting the preset condition in the first equipment list and the second equipment list.
6. The device discovery method according to any of claims 1 to 4, wherein the device detail information includes at least one of the following or any combination thereof: device name, device picture, device attributes, and device interaction specification.
7. A bluetooth broadcasting method, comprising:
setting an identification field in the Bluetooth broadcast information according to a preset rule; wherein, the bluetooth broadcast information at least comprises: a basic device description; the identification field is used for searching the device detailed information matched with the identification field in the mapping relation between the pre-stored identification field and the device detailed information of the Bluetooth device;
and starting the discovered state of the Bluetooth device, and broadcasting the Bluetooth broadcast information.
8. An apparatus for discovering devices, comprising:
the Bluetooth scanning module is used for scanning the broadcast of the Bluetooth equipment and acquiring the identification field in the broadcast;
the information searching module is used for searching the device detailed information matched with the acquired identification field according to the mapping relation between the pre-stored identification field and the device detailed information of the Bluetooth device when the identification field is the identification field set according to the preset rule;
and the information display module is used for displaying the detailed equipment information on a Bluetooth equipment display interface when receiving the Bluetooth equipment display instruction.
9. A bluetooth broadcasting apparatus, comprising:
the identification generation module is used for setting an identification field in the Bluetooth broadcast information according to a preset rule; wherein, the bluetooth broadcast information at least comprises: a basic device description; the identification field is used for searching the device detailed information matched with the identification field in the mapping relation between the pre-stored identification field and the device detailed information of the Bluetooth device;
and the Bluetooth function module is used for starting the discovered state of the Bluetooth equipment and broadcasting the Bluetooth broadcast information.
10. An electronic device, comprising:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the device discovery method of any one of claims 1 to 6 or the bluetooth broadcast method of claim 7.
11. A computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the device discovery method of any one of claims 1 to 6 or the bluetooth broadcast method of claim 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010910743.8A CN112105009A (en) | 2020-09-02 | 2020-09-02 | Device discovery and Bluetooth broadcasting method, device, electronic device and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010910743.8A CN112105009A (en) | 2020-09-02 | 2020-09-02 | Device discovery and Bluetooth broadcasting method, device, electronic device and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN112105009A true CN112105009A (en) | 2020-12-18 |
Family
ID=73757538
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010910743.8A Pending CN112105009A (en) | 2020-09-02 | 2020-09-02 | Device discovery and Bluetooth broadcasting method, device, electronic device and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112105009A (en) |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112738786A (en) * | 2020-12-31 | 2021-04-30 | 展讯通信(上海)有限公司 | Bluetooth communication method, first electronic device and second electronic device |
CN113162997A (en) * | 2021-04-02 | 2021-07-23 | 深圳市网旭科技有限公司 | Data transmission method and device, electronic equipment and readable storage medium |
CN113225692A (en) * | 2021-04-21 | 2021-08-06 | 北京锐达仪表有限公司 | Instrument searching and connecting method, device, system, equipment and storage medium |
CN113473386A (en) * | 2021-06-02 | 2021-10-01 | Tcl通讯(宁波)有限公司 | Method and device for acquiring low-power-consumption Bluetooth information, mobile terminal and storage medium |
CN113490194A (en) * | 2021-08-02 | 2021-10-08 | Oppo广东移动通信有限公司 | Bluetooth-based equipment connection method and device, electronic equipment and storage medium |
CN115474181A (en) * | 2022-03-02 | 2022-12-13 | 北京罗克维尔斯科技有限公司 | Bluetooth device identification method and device, electronic device and storage medium |
CN116017412A (en) * | 2022-12-27 | 2023-04-25 | 苏州融硅新能源科技有限公司 | Gateway equipment, method and system for acquiring equipment information |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105827638A (en) * | 2016-05-10 | 2016-08-03 | 腾讯科技(深圳)有限公司 | Data transmission method, device and system |
JP2017076939A (en) * | 2015-10-16 | 2017-04-20 | 日本電信電話株式会社 | Wireless system, wireless transmission device, terminal device, and identification information notification method |
US20180139576A1 (en) * | 2016-11-16 | 2018-05-17 | Institute For Information Industry | Wireless device, server, index data providing method for wireless device, data providing method for server and wireless transmission system |
JP2019003526A (en) * | 2017-06-19 | 2019-01-10 | 住友電気工業株式会社 | Management support device, terminal equipment, equipment management system, equipment management method, display processing method, equipment management program, and display processing program |
CN109525540A (en) * | 2017-09-20 | 2019-03-26 | 中移(杭州)信息技术有限公司 | A kind of smart machine binding method and device |
CN109862549A (en) * | 2019-03-28 | 2019-06-07 | 南昌黑鲨科技有限公司 | Bluetooth connection method and device, readable storage medium and mobile device |
CN110602671A (en) * | 2018-10-17 | 2019-12-20 | 深圳市文鼎创数据科技有限公司 | Bluetooth search result display method and device, terminal equipment and storage medium |
CN110636477A (en) * | 2018-06-21 | 2019-12-31 | 腾讯科技(深圳)有限公司 | Device connection method, device, terminal and storage medium |
-
2020
- 2020-09-02 CN CN202010910743.8A patent/CN112105009A/en active Pending
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2017076939A (en) * | 2015-10-16 | 2017-04-20 | 日本電信電話株式会社 | Wireless system, wireless transmission device, terminal device, and identification information notification method |
CN105827638A (en) * | 2016-05-10 | 2016-08-03 | 腾讯科技(深圳)有限公司 | Data transmission method, device and system |
US20180139576A1 (en) * | 2016-11-16 | 2018-05-17 | Institute For Information Industry | Wireless device, server, index data providing method for wireless device, data providing method for server and wireless transmission system |
JP2019003526A (en) * | 2017-06-19 | 2019-01-10 | 住友電気工業株式会社 | Management support device, terminal equipment, equipment management system, equipment management method, display processing method, equipment management program, and display processing program |
CN109525540A (en) * | 2017-09-20 | 2019-03-26 | 中移(杭州)信息技术有限公司 | A kind of smart machine binding method and device |
CN110636477A (en) * | 2018-06-21 | 2019-12-31 | 腾讯科技(深圳)有限公司 | Device connection method, device, terminal and storage medium |
CN110602671A (en) * | 2018-10-17 | 2019-12-20 | 深圳市文鼎创数据科技有限公司 | Bluetooth search result display method and device, terminal equipment and storage medium |
CN109862549A (en) * | 2019-03-28 | 2019-06-07 | 南昌黑鲨科技有限公司 | Bluetooth connection method and device, readable storage medium and mobile device |
Cited By (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112738786A (en) * | 2020-12-31 | 2021-04-30 | 展讯通信(上海)有限公司 | Bluetooth communication method, first electronic device and second electronic device |
CN112738786B (en) * | 2020-12-31 | 2022-11-04 | 展讯通信(上海)有限公司 | Bluetooth communication method, first electronic device and second electronic device |
CN113162997A (en) * | 2021-04-02 | 2021-07-23 | 深圳市网旭科技有限公司 | Data transmission method and device, electronic equipment and readable storage medium |
CN113162997B (en) * | 2021-04-02 | 2022-04-12 | 深圳市网旭科技有限公司 | Data transmission method and device, electronic equipment and readable storage medium |
CN113225692A (en) * | 2021-04-21 | 2021-08-06 | 北京锐达仪表有限公司 | Instrument searching and connecting method, device, system, equipment and storage medium |
CN113225692B (en) * | 2021-04-21 | 2022-04-19 | 北京锐达仪表有限公司 | Instrument searching and connecting method, device and system and instrument |
CN113473386A (en) * | 2021-06-02 | 2021-10-01 | Tcl通讯(宁波)有限公司 | Method and device for acquiring low-power-consumption Bluetooth information, mobile terminal and storage medium |
CN113490194A (en) * | 2021-08-02 | 2021-10-08 | Oppo广东移动通信有限公司 | Bluetooth-based equipment connection method and device, electronic equipment and storage medium |
CN115474181A (en) * | 2022-03-02 | 2022-12-13 | 北京罗克维尔斯科技有限公司 | Bluetooth device identification method and device, electronic device and storage medium |
CN116017412A (en) * | 2022-12-27 | 2023-04-25 | 苏州融硅新能源科技有限公司 | Gateway equipment, method and system for acquiring equipment information |
CN116017412B (en) * | 2022-12-27 | 2024-04-16 | 苏州融硅新能源科技有限公司 | Gateway equipment, method and system for acquiring equipment information |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112105009A (en) | Device discovery and Bluetooth broadcasting method, device, electronic device and storage medium | |
CN105744466B (en) | A kind of connection method of Bluetooth device and bluetooth equipment | |
CN110032512B (en) | Debugging method of small program, related equipment and terminal | |
CN111866998A (en) | Bluetooth network distribution method, equipment and storage medium | |
KR20120055166A (en) | Method and apparatus for syncronizing data in connected devices | |
CN106789466B (en) | Method for controlling intelligent household appliance, mobile terminal and intelligent household appliance | |
US11909840B2 (en) | Resource subscription method, device, and storage medium | |
US20220022022A1 (en) | Device discovery method and apparatus, control terminal, and internet of things auxiliary device | |
CN108259523B (en) | Data transmission method, Internet of things system and network access method | |
CN104023055A (en) | Video sharing method and system, and terminal device | |
CN107734592B (en) | core network selection method, access network entity, UE and system | |
CN109067735B (en) | Dynamic configuration method of communication protocol, wireless communication device and intelligent equipment | |
CN109218994B (en) | Equivalent equipment Bluetooth communication method and device based on gateway | |
CN116782317A (en) | Roaming guide method, device, equipment, storage medium and system | |
CN108052401B (en) | System attribute monitoring method, terminal device and computer readable storage medium | |
CN111343506B (en) | Video searching method, device, system, server and readable storage medium | |
EP4456495A1 (en) | Function updating method and related apparatus | |
CN111404788A (en) | Equipment sharing method and server | |
CN113518314B (en) | Quick connection method for low-power-consumption Bluetooth and low-power-consumption Bluetooth communication system | |
CN107241628B (en) | Configuration synchronization method of television equipment, television equipment and storage medium | |
CN111193805B (en) | Resource discovery method and device | |
CN114755934A (en) | Control method of household equipment and household equipment | |
CN108712497B (en) | Application mode sharing method, device and system | |
CN112152850A (en) | Internet of things equipment management method based on IGRS (intelligent grouping and resource sharing) protocol and business terminal | |
CN116684942B (en) | Network access method, electronic equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20201218 |
|
RJ01 | Rejection of invention patent application after publication |