Bluetooth device networking method, device and equipment
Receive and convert service requests of Bluetooth devices through the client standard protocol, determine the communication link and transmit it to the server, solving the problem of poor adaptability of Bluetooth devices and real-time interaction functions of multiple types of Bluetooth devices.
Patent Information
- Application Number
- CN202310378142.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-04-07
- Publication Date
- 2025-08-22
- Estimated Expiration
- 2043-04-07
AI Technical Summary
The networking solutions of existing Bluetooth devices are not very adaptable and it is difficult to meet the networking needs of multiple types of Bluetooth devices at the same time. Especially under cost and power consumption considerations, it lacks the ability to interact with remote servers periodically or real-time networks.
Provides a networking method for Bluetooth devices, which receives and converts service requests through client standard protocols, determines communication links, and transmits requests to servers, supporting a wide range of adaptations of different types of Bluetooth devices, including the development of protocol aggregation layer and the guidance of vendor applications.
It realizes the wide adaptive networking capabilities of different types of Bluetooth devices, ensures stable communication between Bluetooth devices and remote servers, and meets the real-time or periodic networking needs of functions such as scanning code payment.
Smart Images

Figure CN116471576B_ABST
Abstract
Description
Technical Field
[0001] This specification relates to the field of Internet technology, and in particular to methods, devices, and equipment for networking Bluetooth devices. Background Art
[0002] With the development of the Internet of Things, Bluetooth devices are becoming increasingly diverse. Due to cost and power consumption considerations, some smart wearable watches lack networking capabilities, meaning they lack the ability to make periodic or near-real-time network requests to remote servers. To overcome this weakness, some device manufacturers offer Bluetooth device networking via mobile devices or manufacturer applications. However, these are generally closed-source solutions, making it difficult to simultaneously meet the networking needs of an increasing number of Bluetooth devices and limiting their adaptability.
[0003] Based on this, a more adaptable networking solution for Bluetooth devices is needed. Summary of the Invention
[0004] The embodiments of this specification provide a method, apparatus, device, and storage medium for networking a Bluetooth device to solve the following technical problem: a Bluetooth device networking solution with wider adaptability is needed.
[0005] To solve the above technical problems, one or more embodiments of this specification are implemented as follows:
[0006] In a first aspect, an embodiment of the present specification provides a method for networking a Bluetooth device, which is applied to a client, and the method includes: receiving a service request sent by a Bluetooth device using a client standard protocol; obtaining first device information of the Bluetooth device; determining a communication link based on the first device information, wherein the communication link uses the client standard protocol; and transmitting the service request to a server via the communication link.
[0007] In a second aspect, an embodiment of the present specification provides another networking method for a Bluetooth device, which is applied to a Bluetooth device, and the method includes: generating a service request and determining the protocol type of the service request; converting the protocol type of the service request into a client standard protocol; sending a service request using the client standard protocol to the client, so that the client determines a communication link, and transmits the service request to the server based on the communication link.
[0008] In a third aspect, corresponding to the first aspect, an embodiment of this specification provides a networking device for a Bluetooth device, which is applied to a client, and the device includes: a receiving module, which receives a service request sent by a Bluetooth device using a client standard protocol; an acquisition module, which acquires first device information of the Bluetooth device; a determination module, which determines a communication link based on the first device information, wherein the communication link uses the client standard protocol; and a transmission module, which transmits the service request to a back-end server through the communication link.
[0009] In a fourth aspect, corresponding to the second aspect, an embodiment of this specification provides a networking device for a Bluetooth device, which is applied to a Bluetooth device, and the device includes: a generation module, which generates a service request and determines the protocol type of the service request; a conversion module, which converts the protocol type of the service request into a client standard protocol; and a sending module, which sends a service request using the client standard protocol to the client, so that the client determines a communication link and transmits the service request to the server based on the communication link.
[0010] In a fifth aspect, one or more embodiments of this specification provide an electronic device, including:
[0011] at least one processor; and,
[0012] a memory communicatively connected to the at least one processor; wherein,
[0013] The memory stores instructions that can be executed by the at least one processor. The instructions are executed by the at least one processor to enable the at least one processor to perform the method according to the first aspect or the second aspect.
[0014] In a sixth aspect, an embodiment of this specification provides a non-volatile computer storage medium storing computer-executable instructions. When a computer reads the computer-executable instructions in the storage medium, the instructions enable one or more processors to execute the method described in the first aspect.
[0015] At least one of the above-mentioned technical solutions adopted in one or more embodiments of this specification can achieve the following beneficial effects: by receiving a service request sent by a Bluetooth device using the client standard protocol; obtaining the first device information of the Bluetooth device; determining a communication link based on the first device information, wherein the communication link adopts the client standard protocol; transmitting the service request to the server through the communication link, thereby achieving wide adaptability to different types of Bluetooth devices, so that different types of Bluetooth devices can obtain networking capabilities in this way, and have wider adaptability. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the embodiments of this specification or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments recorded in this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0017] Figure 1 A schematic diagram of a flow chart of a method for networking a Bluetooth device according to an embodiment of this specification;
[0018] Figure 2 This is a schematic diagram of the architecture of the Bluetooth device SDK provided in the embodiments of this specification;
[0019] Figure 3 A schematic diagram of a link aggregation provided in an embodiment of the present application;
[0020] Figure 4 A schematic diagram of the system architecture of a device where a client is located provided in an embodiment of the present application;
[0021] Figure 5 A schematic diagram of a flow chart of another method for networking a Bluetooth device provided in an embodiment of this specification;
[0022] Figure 6 A schematic diagram of the structure of a networking device for a Bluetooth device provided in an embodiment of this specification;
[0023] Figure 7 A schematic diagram of the structure of another Bluetooth device networking device provided in an embodiment of this specification;
[0024] Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this specification. DETAILED DESCRIPTION
[0025] The embodiments of this specification provide a method, apparatus, device, and storage medium for networking a Bluetooth device.
[0026] In order to help those skilled in the art better understand the technical solutions in this specification, the technical solutions in the embodiments of this specification will be clearly and completely described below in conjunction with the drawings in the embodiments of this specification. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments of this specification, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of this application.
[0027] Current Bluetooth devices, especially wearable smart Bluetooth devices, generally do not have networking capabilities due to cost and power consumption considerations. The networking function here refers to the function that the Bluetooth device cannot autonomously interact with a remote server.
[0028] However, in practice, some features of these devices also require internet access. For example, when a Bluetooth watch provides a scan-to-pay service, it needs to obtain both the payment code and the receipt code from the server. The payment code might not need to change for a week (a Bluetooth watch might need to interact with the server once a week to update the payment code, requiring periodic internet access), while a payment card might expire in a minute (a Bluetooth watch might need to interact with the server once a minute to update the payment code, requiring a near-real-time internet connection).
[0029] In order to achieve this function, current Bluetooth device manufacturers have also provided some corresponding solutions:
[0030] First, for manufacturers that produce both mobile phones and Bluetooth devices, they build their own device communication link between the Bluetooth device and the mobile phone based on the operating systems built into their mobile phones and Bluetooth devices. However, this link is relatively closed and generally cannot be ported to other Bluetooth devices.
[0031] The second method is for manufacturers that can only produce Bluetooth devices. They will generally develop corresponding manufacturer applications based on Android and IOS systems, and establish communication links with their own Bluetooth devices through the manufacturer applications. This method is also relatively closed. On the one hand, the manufacturer application can generally only be provided to its own Bluetooth device for connection, the connection is unstable, and the background operation is easily restricted; on the other hand, for users, this method means that every time a new manufacturer's Bluetooth device is used, a new manufacturer application needs to be downloaded and installed, which is a very poor experience. Based on this, the embodiments of this specification provide a networking solution for Bluetooth devices to accommodate a wider range of Bluetooth devices. The embodiments of this specification include two aspects: the client and the Bluetooth device.
[0032] In the first aspect, Figure 1 As shown, Figure 1 This is a flow chart of a method for networking a Bluetooth device provided in an embodiment of this specification, which is applied to a client. Figure 1 The process in may include the following steps:
[0033] S101: receiving a service request sent by a Bluetooth device using a client standard protocol.
[0034] On Bluetooth devices, the internal protocols that may be used will be quite different based on the different device types used by manufacturers, the different chip types used in the devices, and the different services provided.
[0035] For example, some Bluetooth devices may only need to use the BLE standard protocol to provide functions provided by the manufacturer, while other Bluetooth devices may use manufacturer-specific protocols to provide some customized functions. In order to adapt to a wide range of Bluetooth devices, a set of software development kits (SDKs) corresponding to Bluetooth devices are also provided during the development process. Figure 2 As shown, Figure 2 This is a schematic diagram of the architecture of the Bluetooth device SDK provided in the embodiments of this specification.
[0036] Based on this architecture, different types of protocols can be selected based on actual needs during the development process, and through protocol adaptation, a set of client standard protocols can be provided at the protocol aggregation layer, so that any protocol used in the Bluetooth device can be converted into a client standard protocol for external communication.
[0037] This development process can be done by the client providing the corresponding platform, and the manufacturer adapting and aggregating the private protocol on the platform, and finally porting the generated corresponding code to its own Bluetooth device. In other words, this process is not complicated for Bluetooth device manufacturers. They only need to provide the corresponding private protocol and adapt it to the client's standard protocol. The code that needs to be ported will not contain other irrelevant protocol types. In this way, Bluetooth devices can not only implement standard BLE standard protocol interaction, but also bridge and be compatible with the manufacturer's private protocol, maximizing the use of existing link functions.
[0038] The service request may include establishing a connection, binding, waking up a device, forwarding data, proxy requesting a network service, business requesting service, etc. The service request requires networking functionality, that is, communication between the Bluetooth device and a remote server.
[0039] S103: Acquire first device information of the Bluetooth device.
[0040] The first device information includes the device model, chip signal, and manufacturer of the Bluetooth device, etc. The Bluetooth device may carry the first device information during the process of sending the service request. In addition, the client may also obtain the first device information of the Bluetooth devices in the surrounding environment by scanning.
[0041] For example, the client obtains the type of Bluetooth device as "Mi Smart Band 6" through the Bluetooth scanning function provided by its own device, thereby knowing the corresponding wristband type, and then obtains the device model, chip signal and manufacturer corresponding to the wristband type.
[0042] S105: Determine a communication link according to the first device information, wherein the communication link adopts the client standard protocol.
[0043] After the client obtains the first device information of the Bluetooth device, it needs to determine the corresponding communication link between the Bluetooth device and the server to realize the service request requiring networking functionality. Because different communication links have been pre-aggregated in the client, it can now perform a corresponding match based on the first device information (i.e., the device model, chip signal, and manufacturer of the Bluetooth device) to determine the communication link. When transmitting information in the determined communication link, the aforementioned client standard protocol is used.
[0044] In one embodiment, the communication link is determined based on the first device information, and the communication link can be determined based on the first device information and the service request type; or, the second device information of the device where the client is located is obtained, and the communication link is determined based on the first device information and the second device information.
[0045] The preset device set includes the device information of the Bluetooth devices that have been aggregated with the corresponding protocol through the aforementioned SDK, or the device information of the Bluetooth devices in the preset device set that have been pre-authorized by the client (that is, the Bluetooth device has been authorized by the client to provide related customized services through the client).
[0046] In other words, the Bluetooth devices included in the preset device set are typically those that use proprietary protocols to provide customized services. For these Bluetooth devices, users typically need to pre-install the corresponding manufacturer's application on their local device to enable customized service requests unique to that Bluetooth device.
[0047] The service request type here can specifically include whether it matches the client type. That is, whether the client can provide corresponding functional support for the service request. For example, if the service request type is "obtain payment code" and the client type is "payment", then the two can be considered to match; or, the correspondence between the service request type and the client type can be pre-established and stored in the client, so that the client can query whether the corresponding service request type matches the client based on this locally stored correspondence. When a match is found, the manufacturer application can be skipped and a communication link between the Bluetooth device and the client can be established.
[0048] As previously mentioned, Bluetooth devices communicate using a standard client protocol. This is a protocol that clients can recognize and parse, and is used for internal client communication or communication with a corresponding server. Therefore, a seamless communication link can be established between the client and the Bluetooth device. Since the client can connect to a remote server, communication between the Bluetooth device and the remote server can be achieved over this communication link.
[0049] In this embodiment, when it is found that the first device information belongs to a preset device set and the service request type does not match the client, it can be known that the client service cannot provide the corresponding function for the service request of the Bluetooth device. In other words, the service request requires the corresponding application of the Bluetooth device to customize the service before it can be implemented. At this time, the manufacturer application corresponding to the first device information can be determined through client guidance (usually pre-configured in the client), so that the client can start the manufacturer application and establish a communication link between the Bluetooth device and the manufacturer application, and connect to the remote server through the manufacturer application.
[0050] In one embodiment, when determining a communication link based on the first device information and the second device information, the first device information and the second device information can be matched. When the first device information matches the second device information, the device communication link provided by the device where the client is located is determined; and a communication link is established between the Bluetooth device, the device communication link, and the client.
[0051] The matching conditions of the first device information and the second device information may include, for example: the same manufacturer or the same device model, etc. The Bluetooth device and the device where the client is located are both manufactured by the same manufacturer, and the Bluetooth device may even be a peripheral device of the device where the client is located. In this case, the manufacturer will usually design a device communication link between its own devices based on the capabilities of chips such as Bluetooth, WiFi, NFC, and development engines. Then, based on this device communication link, communication between the Bluetooth device and the device where the client is located is realized, including proxying and forwarding network requests from the Bluetooth device. Because the entire device communication link, including chips, systems, and devices, is controlled by the manufacturer itself, the stability of this link is usually better.
[0052] In one embodiment, when the first device information does not belong to the preset device set (i.e., the Bluetooth device is not a preset manufacturer device), a standard communication link provided by the operating system of the client device is used to establish a communication link between the Bluetooth device and the standard communication link. In this operation mode, a communication link with the Bluetooth device is established using the universal Bluetooth capabilities provided by the operating system.
[0053] In addition, it should be noted that if the Bluetooth device itself has 4G / 5G networking capabilities, for example, some Bluetooth devices can interact with remote servers through cellular networks (CAT1 / CAT4), then the solution of this application is also compatible with such Bluetooth devices. And when the 4G / 5G networking function of the Bluetooth device is not available, the solution of this application can be used to connect to the network. Figure 3 As shown, Figure 3 A schematic diagram of a link aggregation provided for an embodiment of the present application. As can be seen from the schematic diagram, a complete communication link should include a complete link from service initiation to the server. For example, for a customized service, the corresponding communication link should be from initiating customized service → sending request → manufacturer application → gateway → server. In addition, the data reflux part is omitted in the schematic diagram. Generally speaking, the communication link used for data reflux is the same link, but the data flow direction is reversed.
[0054] S107: Transmit the service request to the server via the communication link.
[0055] After the communication link is established, the service request will be forwarded to the server through the gateway based on different communication links to realize the networking function of the Bluetooth device. Figure 4 As shown, Figure 4 This is a schematic diagram of the system architecture of a client device provided in an embodiment of the present application. Through this architecture, the client is adapted to different operating systems, platforms and a wide range of communication protocols, thereby achieving unified Bluetooth services for various Bluetooth devices.
[0056] By receiving a service request using a client standard protocol sent by a Bluetooth device; obtaining first device information of the Bluetooth device; determining a communication link based on the first device information, wherein the communication link uses the client standard protocol; and transmitting the service request to a server through the communication link, it is possible to achieve wide adaptability to different types of Bluetooth devices, so that different types of Bluetooth devices can obtain networking capabilities through this method, and have wider adaptability.
[0057] In one embodiment, when determining the communication link based on the first device, especially when the client and the Bluetooth device establish a communication connection for the first time, the client can scan the surrounding Bluetooth devices based on the Bluetooth device scanning function provided by the device, and obtain the universal identification code (Universally Unique Identifier, UUID) contained in the first device information of the Bluetooth device; and establish a communication link with the client based on the universal identification code.
[0058] Specifically, the client scans surrounding devices, scans bluetoothDevice to obtain bluetoothSocket(UUID), and then uses bluetoothSocket.connect(UUID) to connect to the surrounding Bluetooth devices, where UUID is the UUID specified by the Bluetooth device.
[0059] The Bluetooth device obtains the universal identification code BluetoothServerSocket(Name, UUID) through the Bluetooth adapter. Both the Name and UUID are assigned by the Bluetooth device's smart device. The client connects to the Bluetooth device through this UUID, establishing communication between the two parties. In this way, a listening service port with a name and unique identification is created to establish a communication link between the two parties.
[0060] It should be noted that the communication link established at this time is only the communication between the Bluetooth device and the client, or in other words, the communication link implemented at this time does not need or may not have realized the networking function.
[0061] In one embodiment, when multiple Bluetooth devices are located near a client, they can form an ad hoc Bluetooth network. Bluetooth devices within the Bluetooth network can communicate with each other using a publish / subscribe messaging system. Any device in the Bluetooth network can act as a relay to retransmit messages received from other devices. A single message can be relayed multiple times, ensuring that all devices within range receive it.
[0062] Based on this, when establishing the initial connection, when the client scans multiple Bluetooth devices, it can communicate from any device in the Bluetooth network composed of the Bluetooth devices, receive the universal identification code contained in the first device information of the Bluetooth device broadcast by the Bluetooth network, and then establish communication with the Bluetooth device based on the universal identification code and determine the subsequent communication link.
[0063] In the second aspect, Figure 5 As shown, Figure 5This is a flow chart of another method for networking a Bluetooth device provided in an embodiment of this specification, which is applied to a Bluetooth device. The method includes:
[0064] S501, generating a service request and determining a protocol type of the service request;
[0065] S503, converting the protocol type of the service request into a client standard protocol;
[0066] S505 : Sending a service request using the client standard protocol to the client, so that the client determines a communication link and transmits the service request to the server based on the communication link.
[0067] Service requests may include establishing connections, binding, waking up devices, forwarding data, proxying network service requests, and business service requests (such as payment, ride-hailing, and public welfare).
[0068] As mentioned above Figure 2 As shown, compared with conventional Bluetooth devices, this Bluetooth device provides a protocol aggregation layer during the development process to adapt and convert the protocol, so that it can adapt to a wide range of different types of Bluetooth devices and enable them to obtain networking capabilities.
[0069] In order to make the solutions of the embodiments of this specification clearer, a specific embodiment is given below for illustration.
[0070] The client first performs a Bluetooth scan to obtain the first device information of the surrounding Bluetooth devices. When establishing the first connection, based on the universal identification code (UUID) provided by the Bluetooth device, a listening service port is established, and then a connection is established with the Bluetooth device based on the listening service port. This connection usually does not require the network function of the remote server.
[0071] After the connection is established, the Bluetooth device sends a corresponding service request (for example, a payment service or a customized service). After receiving the server request, the client determines the communication link based on the first device information.
[0072] Since protocol adaptation and aggregation are pre-integrated in the Bluetooth device, the service request sent by the Bluetooth device can adopt the client standard protocol, and the established communication link will also at least partially adopt the client standard protocol for information transmission.
[0073] For example, assuming the Bluetooth device is an authorized manufacturer and the service request is for a payment service that the client can support (including obtaining a payment code, obtaining a receipt code, and querying payment accounts). A communication link is established between the Bluetooth device and the client. The client forwards the service request to a remote server via the communication link. The client then completes the payment service through proxy and forwarding. For example, the request to obtain a receipt code is forwarded to the server, the server returns the receipt code, and the receipt code is sent to the Bluetooth device via the communication link.
[0074] For another example, suppose that after matching, it is found that the first device information matches the second device information, that is, the Bluetooth device and the device where the client is located are manufactured by the same manufacturer, and the device models or chip functions match (for example, both are Huawei devices configured with WearEngine), and the manufacturer has pre-provided a device communication link between its various devices. Then, for the service request, the device communication link provided by the manufacturer is used to establish a communication link between the Bluetooth device, the device communication link and the client for 4G / 5G networking, thereby achieving more stable communication.
[0075] For another example, assuming that it is found that the Bluetooth device does not belong to the preset device set, that is, the relevant functions of the Bluetooth device have not been authorized by the client, then the standard communication link provided by the operating system of the device where the client is located can be used to establish a communication link between the Bluetooth device and the standard communication link for 4G / 5G networking.
[0076] Based on the above examples, it can be found that the embodiments of the present application can be widely adapted to different types of Bluetooth devices to achieve Bluetooth device networking. In addition, when facing different service requests from the same Bluetooth device, the appropriate communication link can also be selected based on the device type and service request type.
[0077] Based on the same idea, one or more embodiments of this specification also provide devices and apparatuses corresponding to the above methods, such as Figure 6 、 Figure 7 shown.
[0078] In a third aspect, corresponding to the first aspect, the embodiment of this specification further provides a Bluetooth device networking device, which is applied to a client, such as Figure 6 As shown, Figure 6 This is a schematic diagram of a Bluetooth device networking device provided in an embodiment of this specification, the device comprising:
[0079] Receiving module 601, receiving a service request using a client standard protocol sent by a Bluetooth device;
[0080] An acquisition module 603 acquires first device information of the Bluetooth device;
[0081] A determination module 605 determines a communication link according to the first device information, wherein the communication link adopts the client standard protocol;
[0082] The transmission module 607 transmits the service request to the backend server via the communication link.
[0083] Optionally, the determination module 605 determines the communication link according to the first device information and the service request type; or obtains second device information of the device where the client is located, and determines the communication link according to the first device information and the second device information.
[0084] Optionally, the determination module 605, when the first device information belongs to a preset device set and the service request type does not match the client, determines the manufacturer application corresponding to the first device information and establishes a communication link between the Bluetooth device and the manufacturer application; or, when the first device information belongs to a preset device set and the service request type matches the client, establishes a communication link between the Bluetooth device and the client.
[0085] Optionally, when the first device information matches the second device information, the determining module 605 determines a device communication link provided by the device where the client is located; and establishes a communication link between the Bluetooth device, the device communication link, and the client.
[0086] Optionally, when the first device information does not belong to the preset device set, the determination module 605 determines a standard communication link provided by the operating system of the device where the client is located, and establishes a communication link between the Bluetooth device and the standard communication link.
[0087] Optionally, the determining module 605 scans surrounding Bluetooth devices to obtain a universal identification code included in the first device information of the Bluetooth device; and establishes a communication link with the client according to the universal identification code.
[0088] Optionally, the determining module 605 determines a Bluetooth network formed by the multiple Bluetooth devices, and receives a universal identification code included in the first device information of the Bluetooth device broadcast by the Bluetooth network.
[0089] In a fourth aspect, corresponding to the second aspect, the embodiments of this specification also provide another Bluetooth device networking device, which is applied to a Bluetooth device, such as Figure 7 As shown, Figure 7This is a schematic diagram of the structure of another Bluetooth device networking device provided in an embodiment of this specification, the device comprising:
[0090] A generating module 701 generates a service request and determines a protocol type of the service request;
[0091] The conversion module 703 converts the protocol type of the service request into a client standard protocol;
[0092] The sending module 705 sends a service request using the client standard protocol to the client, so that the client determines a communication link and transmits the service request to the server based on the communication link.
[0093] In the fifth aspect, Figure 8 As shown, Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this specification, the device comprising:
[0094] at least one processor; and,
[0095] a memory communicatively connected to the at least one processor; wherein,
[0096] The memory stores instructions that can be executed by the at least one processor. The instructions are executed by the at least one processor to enable the at least one processor to perform the method according to the first aspect or the second aspect.
[0097] In the sixth aspect, based on the same idea, an embodiment of this specification also provides a non-volatile computer storage medium corresponding to the above method, which stores computer-executable instructions. When the computer reads the computer-executable instructions in the storage medium, the instructions enable one or more processors to execute the method described in the first aspect or the second aspect.
[0098] In the 1990s, technological improvements could be clearly distinguished as either hardware improvements (for example, improvements to circuit structures like diodes, transistors, and switches) or software improvements (improvements to process flows). However, with the advancement of technology, many process flow improvements today can now be considered direct improvements to hardware circuit structures. Designers almost always create the corresponding hardware circuit structure by programming the improved process flow into the hardware circuit. Therefore, it cannot be said that a process flow improvement cannot be implemented using hardware modules. For example, a programmable logic device (PLD), such as a field programmable gate array (FPGA), is an integrated circuit whose logical function is determined by user programming. Designers can "integrate" a digital system on a PLD through their own programming, without having to hire a chip manufacturer to design and manufacture a dedicated integrated circuit chip. Moreover, nowadays, instead of manually fabricating integrated circuit chips, this programming is mostly done using "logic compiler" software. This is similar to the software compiler used when developing programs. Before compilation, the original code must also be written in a specific programming language, called a hardware description language (HDL). There is not just one HDL, but many, such as ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, RHDL (Ruby Hardware Description Language), etc. The most commonly used ones are VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) and Verilog. Those skilled in the art will also understand that by simply programming the method flow in one of these hardware description languages and then programming it into an integrated circuit, a hardware circuit that implements the logic method flow can be easily obtained.
[0099] The controller can be implemented in any suitable manner. For example, the controller can take the form of a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro)processor, logic gates, switches, application-specific integrated circuits (ASICs), programmable logic controllers, and embedded microcontrollers. Examples of controllers include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320. The memory controller can also be implemented as part of the control logic of the memory. Those skilled in the art will also know that in addition to implementing the controller in a purely computer-readable program code format, the controller can be implemented in the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, and embedded microcontrollers by logically programming the method steps. Therefore, such a controller can be considered a hardware component, and the devices included therein for implementing various functions can also be considered as structures within the hardware component. Or even, the devices for implementing various functions can be considered as both software modules that implement the method and structures within the hardware component.
[0100] The systems, devices, modules, or units described in the above embodiments may be implemented by computer chips or entities, or by products having certain functions. A typical implementation device is a computer. Specifically, the computer may be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
[0101] For the convenience of description, the above devices are described as being divided into various units according to their functions. Of course, when implementing this specification, the functions of each unit can be implemented in the same or multiple software and / or hardware.
[0102] Those skilled in the art will appreciate that the embodiments of this specification may be provided as methods, systems, or computer program products. Therefore, the embodiments of this specification may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the embodiments of this specification may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0103] This specification is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of this specification. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0104] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.
[0105] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 The steps for the function specified in one or more boxes.
[0106] In a typical configuration, a computing device includes one or more processors (CPUs), input / output interfaces, network interfaces, and memory.
[0107] Memory may include non-permanent storage in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. Memory is an example of a computer-readable medium.
[0108] Computer-readable media includes permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. The information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include transitory computer-readable media (transitory media), such as modulated data signals and carrier waves.
[0109] It should also be noted that the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, commodity, or apparatus that includes a series of elements includes not only those elements but also other elements not explicitly listed, or includes elements inherent to such process, method, commodity, or apparatus. In the absence of further limitations, an element defined by the phrase "comprises a ..." does not exclude the presence of other identical elements in the process, method, commodity, or apparatus that includes the element.
[0110] This specification may be described in the general context of computer-executable instructions, such as program modules, executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, and the like that perform specific tasks or implement specific abstract data types. This specification may also be practiced in distributed computing environments where tasks are performed by remote processing devices connected through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media, including storage devices.
[0111] The various embodiments in this specification are described in a progressive manner. Similar portions between the various embodiments can be referenced to each other, and each embodiment focuses on the differences from the other embodiments. In particular, the device, apparatus, and non-volatile computer storage medium embodiments are generally similar to the method embodiments, so their descriptions are relatively simplified. For relevant details, refer to the descriptions of the method embodiments.
[0112] The foregoing description of this specification describes specific embodiments. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims can be performed in an order different from that described in the embodiments and still achieve the desired results. Furthermore, the processes depicted in the accompanying drawings do not necessarily require the specific order shown or the sequential order to achieve the desired results. In certain embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0113] The foregoing description is merely one or more embodiments of this specification and is not intended to limit this specification. It will be apparent to those skilled in the art that various modifications and variations may be made to one or more embodiments of this specification. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of one or more embodiments of this specification are intended to be within the scope of the claims of this specification.
Claims
1. A method for networking a Bluetooth device, applied to a client, comprising: Receive service requests sent by Bluetooth devices using client standard protocols; Acquire first device information of the Bluetooth device; determining a communication link according to the first device information, wherein the communication link adopts the client standard protocol; transmitting the service request to a server via the communication link; Determining the communication link according to the first device information includes: When the first device information belongs to a preset device set and the service request type does not match the client, determining the manufacturer application corresponding to the first device information and establishing a communication link between the Bluetooth device and the manufacturer application; or When the first device information belongs to a preset device set and the service request type matches the client, skipping the manufacturer application and establishing a communication link between the Bluetooth device and the client; In order to adapt to a wide range of Bluetooth devices, a set of corresponding Bluetooth device software development kits (SDKs) are also provided during the development process. Based on the architecture of the Bluetooth device SDK, different types of protocols can be selected according to actual needs during the development process. Through protocol adaptation, a set of client standard protocols are provided at the protocol aggregation layer, so that any protocol used in the Bluetooth device can be converted into client standard protocols for external communication. In this development process, the client provides the corresponding platform, and the manufacturer adapts and aggregates the private protocol on the platform, and finally transplants the generated corresponding code to its own Bluetooth device.
2. The method according to claim 1, wherein Determining a communication link according to the first device information includes: Determine a communication link according to the first device information and service request type; or, Acquire second device information of the device where the client is located, and determine a communication link according to the first device information and the second device information.
3. The method according to claim 2, wherein: Determining a communication link according to the first device information and the second device information includes: When the first device information matches the second device information, determining a device communication link provided by the device where the client is located; A communication link is established between the Bluetooth device, the device communication link, and the client.
4. The method according to claim 1, wherein Determining a communication link according to the first device information includes: When the first device information does not belong to the preset device set, a standard communication link provided by the operating system of the device where the client is located is determined, and a communication link is established between the Bluetooth device and the standard communication link.
5. The method according to claim 1, wherein Determining a communication link according to the first device information includes: Scan the surrounding Bluetooth devices to obtain the universal identification code contained in the first device information of the Bluetooth device; A communication link is established with the client according to the universal identification code.
6. The method according to claim 5, wherein: When there are multiple Bluetooth devices in the surrounding area, obtaining the universal identification code included in the first device information of the Bluetooth device includes: A Bluetooth network formed by the plurality of Bluetooth devices is determined, and a universal identification code included in the first device information of the Bluetooth device broadcasted by the Bluetooth network is received.
7. A method for networking a Bluetooth device, applied to a Bluetooth device, the method comprising: generating a service request and determining a protocol type of the service request; Convert the protocol type of the service request into a client standard protocol; Sending a service request using the client standard protocol to the client, so that the client determines a communication link and transmits the service request to the server based on the communication link; The client determining the communication link includes: When the first device information of the Bluetooth device belongs to a preset device set and the service request type does not match the client, determining the manufacturer application corresponding to the first device information and establishing a communication link between the Bluetooth device and the manufacturer application; or When the first device information belongs to a preset device set and the service request type matches the client, skipping the manufacturer application and establishing a communication link between the Bluetooth device and the client; In order to adapt to a wide range of Bluetooth devices, a set of corresponding Bluetooth device software development kits (SDKs) are also provided during the development process. Based on the architecture of the Bluetooth device SDK, different types of protocols can be selected according to actual needs during the development process. Through protocol adaptation, a set of client standard protocols are provided at the protocol aggregation layer, so that any protocol used in the Bluetooth device can be converted into client standard protocols for external communication. In this development process, the client provides the corresponding platform, and the manufacturer adapts and aggregates the private protocol on the platform, and finally transplants the generated corresponding code to its own Bluetooth device.
8. A Bluetooth device networking device, applied to a client, comprising: A receiving module receives a service request sent by a Bluetooth device using a client standard protocol; An acquisition module, configured to acquire first device information of the Bluetooth device; a determining module, configured to determine a communication link according to the first device information, wherein the communication link adopts the client standard protocol; A transmission module, transmitting the service request to a back-end server via the communication link; Determining the communication link according to the first device information includes: When the first device information belongs to a preset device set and the service request type does not match the client, determining the manufacturer application corresponding to the first device information and establishing a communication link between the Bluetooth device and the manufacturer application; or When the first device information belongs to a preset device set and the service request type matches the client, skipping the manufacturer application and establishing a communication link between the Bluetooth device and the client; In order to adapt to a wide range of Bluetooth devices, a set of corresponding Bluetooth device software development kits (SDKs) are also provided during the development process. Based on the architecture of the Bluetooth device SDK, different types of protocols can be selected according to actual needs during the development process. Through protocol adaptation, a set of client standard protocols are provided at the protocol aggregation layer, so that any protocol used in the Bluetooth device can be converted into client standard protocols for external communication. In this development process, the client provides the corresponding platform, and the manufacturer adapts and aggregates the private protocol on the platform, and finally transplants the generated corresponding code to its own Bluetooth device.
9. A Bluetooth device networking device, applied to a Bluetooth device, the device comprising: A generating module generates a service request and determines a protocol type of the service request; A conversion module, converting the protocol type of the service request into a client standard protocol; a sending module, configured to send a service request using the client standard protocol to the client, so that the client can determine a communication link and transmit the service request to the server based on the communication link; The client determining the communication link includes: When the first device information of the Bluetooth device belongs to a preset device set and the service request type does not match the client, determining the manufacturer application corresponding to the first device information and establishing a communication link between the Bluetooth device and the manufacturer application; or When the first device information belongs to a preset device set and the service request type matches the client, skipping the manufacturer application and establishing a communication link between the Bluetooth device and the client; In order to adapt to a wide range of Bluetooth devices, a set of corresponding Bluetooth device software development kits (SDKs) are also provided during the development process. Based on the architecture of the Bluetooth device SDK, different types of protocols can be selected according to actual needs during the development process. Through protocol adaptation, a set of client standard protocols are provided at the protocol aggregation layer, so that any protocol used in the Bluetooth device can be converted into client standard protocols for external communication. In this development process, the client provides the corresponding platform, and the manufacturer adapts and aggregates the private protocol on the platform, and finally transplants the generated corresponding code to its own Bluetooth device.
10. An electronic device comprising: at least one processor; as well as, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Method and device for data interaction
CN113438628A
Bluetooth headset upgrading method, Bluetooth device and storage medium
CN115913941A