A method for setting the Bluetooth communication packet sending and receiving time mechanism

By setting a master-slave mode packet transmission and reception time mechanism based on the Bluetooth piconet clock, the time management of the Bluetooth system is optimized, the compatibility problem of the Bluetooth system when hardware is replaced is solved, and the applicability and performance of the Bluetooth system are improved.

CN116112903BActive Publication Date: 2026-03-06GUANGZHOU GUOXIN MICRO TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-02-03
Publication Date
2026-03-06

AI Technical Summary

Technical Problem

Existing Bluetooth systems are prone to incompatibility when peripheral hardware devices or different radio frequency devices are replaced, making Bluetooth system porting difficult. In addition, the time management is not refined enough, which affects power consumption optimization and performance improvement.

Method used

Based on the Bluetooth piconet clock, the timing mechanism for Bluetooth communication packet transmission and reception in master and slave modes is set, including the sending and receiving processes. By configuring variable prefetch, RF start, data transmission, RF shutdown and other time parameters, the time management of the Bluetooth system is optimized.

Benefits of technology

It improves the applicability and versatility of the Bluetooth system, simplifies the Bluetooth module adaptation process, reduces power consumption, and enhances system performance and adaptability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116112903B_ABST
    Figure CN116112903B_ABST
Patent Text Reader

Abstract

This invention discloses a method for setting the Bluetooth communication packet transmission and reception time mechanism. This invention is used for transaction scheduling of BR and EDR, and is divided into master mode and slave mode. In master mode, data is transmitted first and then received; in slave mode, data is received first and then transmitted. The master mode operation cycle is sequentially set as follows: transmit data prefetch time, transmit RF start time, transmit data time, transmit RF shutdown time, transmit / receive switching time interval, receive data prefetch time, receive RF start time, receive data time, and receive RF shutdown time. The slave mode operation cycle is sequentially set as follows: receive data prefetch time, receive RF start time, receive data time, receive RF shutdown time, transmit / receive switching time interval, transmit data prefetch time, transmit RF start time, transmit data time, and transmit RF shutdown time. This invention is beneficial for improving the applicability and scope of use of Bluetooth systems and facilitates the porting of Bluetooth systems.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of Bluetooth wireless communication technology and relates to a method for setting the Bluetooth communication packet transmission and reception time mechanism. Background Technology

[0002] During Bluetooth wireless communication, the operation of Bluetooth packet transmission and reception is closely related to various time parameters. A piconet exists with its own Bluetooth clock, each Bluetooth device has its own local clock, and different radio frequency devices require different times to turn on or off. Other factors include various path delays and latency. The Bluetooth local clock, the on / off times of different radio frequency devices, the specified times for transmitting / receiving packet types, hardware path delays, and latency for transmitting / receiving air packets can be combined to create a wide variety of application scenarios. If a fixed configuration is used, changing peripheral hardware or different radio frequency devices will cause system incompatibility, hindering Bluetooth system portability. Furthermore, the Bluetooth protocol only defines the time interval for transmitting and receiving air packets, distinguishing different time intervals based on different packet types, but the specific time management implementation needs further refinement. The combination of multiple time parameters is a crucial element for Bluetooth system power consumption optimization and performance improvement. Properly allocating the combination of various time parameters allows for a clear understanding of the Bluetooth system's operation flow, thus providing a foundation for further power consumption optimization and performance improvement. Summary of the Invention

[0003] The purpose of this invention is to provide a method for setting the Bluetooth communication packet sending and receiving time mechanism.

[0004] The method of this invention is used for transaction scheduling of Bluetooth BR and EDR. The time mechanism is based on the Bluetooth piconet clock and the time interval occupied by different Bluetooth data packets. It includes a sending process and a receiving process, and is divided into master mode and slave mode. In master mode, data is sent first and then received, while in slave mode, data is received first and then sent.

[0005] A sending process is a packet sending cycle, which includes the packet sending time and the sending-receiving interval. The packet sending cycle T1 = n × 625 μs. A receiving process is a packet receiving cycle, which includes the packet receiving time and the sending-receiving interval. The packet receiving cycle T2 = n × 625 μs. According to the Bluetooth protocol, n ∈ [1, 3, 5] depending on the packet type.

[0006] The main mode operation cycle T = T1 + T2. The main mode operation cycle is set sequentially as follows: transmit data prefetch time, transmit RF start time, transmit data time, transmit RF shutdown time, transmit / receive switching time interval, receive data prefetch time, receive RF start time, receive data time, and receive RF shutdown time.

[0007] From the mode operation period T′=T1+T2, the mode operation period is sequentially set as the receive data prefetch time, receive RF start time, receive data time, receive RF shutdown time, transmit / receive switching time interval, transmit data prefetch time, transmit RF start time, transmit data time, and transmit RF shutdown time.

[0008] The data prefetch time, transmit / receive RF start time, and transmit / receive RF shutdown time are configurable times. The transmit / receive data time is determined based on the amount of data transmitted and received. The time interval for transmit / receive switching is the margin after removing other times from the master / slave mode operation cycle.

[0009] The packet sending / receiving time corresponds to the data sending / receiving time; the start point of the packet sending / receiving time lags behind the start point of the data sending / receiving time, and the end point of the packet sending / receiving time is earlier than the end point of the data sending / receiving time; the path delay time is the time between the start point of the packet sending time and the start point of the data sending time, and the time between the end point of the packet receiving time and the end point of the data receiving time; the waiting time is the time between the start point of the packet receiving time and the start point of the data receiving time, and the time between the end point of the packet sending time and the end point of the data sending time. The path delay time and the waiting time are configurable.

[0010] This invention provides systematic management of Bluetooth wireless communication-related time, which is beneficial for improving the applicability and scope of use of Bluetooth systems and facilitates Bluetooth system portability. It also clearly distinguishes the behavior of Bluetooth packet transmission and reception on the timeline, aiding in system management, power consumption optimization, and performance improvement for Bluetooth devices. By modifying only a portion of the time, Bluetooth modules can be adapted to different RF boards, different PCB hardware, and different application environments, improving the versatility and adaptability of Bluetooth modules or devices. Attached Figure Description

[0011] Figure 1 A schematic diagram of the timing mechanism for Bluetooth BR / EDR packet transmission and reception in master mode;

[0012] Figure 2 This is a schematic diagram of the timing mechanism for Bluetooth BR / EDR packet transmission and reception in slave mode. Detailed Implementation

[0013] A method for setting a Bluetooth communication packet sending and receiving time mechanism for BR and EDR transaction scheduling. The time mechanism is based on the Bluetooth piconet clock and the time intervals occupied by different Bluetooth data packets. It includes a sending process and a receiving process, and is divided into master mode and slave mode. In master mode, data is sent first and then received, while in slave mode, data is received first and then sent.

[0014] A sending process is a packet sending cycle, which includes the packet sending time and the sending-receiving interval. The packet sending cycle T1 = n × 625 μs. A receiving process is a packet receiving cycle, which includes the packet receiving time and the sending-receiving interval. The packet receiving cycle T2 = n × 625 μs. According to the Bluetooth protocol, n ∈ [1, 3, 5] depending on the packet type.

[0015] like Figure 1 As shown, the main mode operation cycle T = T1 + T2. The main mode operation cycle is set sequentially as the data prefetch time, the transmit RF start time, the data transmit time, the transmit RF shutdown time, the transmit / receive switching time gap, the receive data prefetch time, the receive RF start time, the receive data transmit time, and the receive RF shutdown time.

[0016] like Figure 2 As shown, from the mode operation period T′=T1+T2, the mode operation period is sequentially set as the receive data prefetch time, receive RF start time, receive data time, receive RF shutdown time, transmit / receive switching time gap, transmit data prefetch time, transmit RF start time, transmit data time, and transmit RF shutdown time.

[0017] The packet sending / receiving time corresponds to the data sending / receiving time; the start point of the packet sending / receiving time lags behind the start point of the data sending / receiving time, and the end point of the packet sending / receiving time is earlier than the end point of the data sending / receiving time; the path delay time is the time between the start point of the packet sending time and the start point of the data sending time, and the time between the end point of the packet receiving time and the end point of the data sending time, which is the hardware lag time; the waiting time is the time between the start point of the packet receiving time and the start point of the data receiving time, and the time between the end point of the packet sending time and the end point of the data sending time, which is to ensure the completion of sending / receiving air packets; the path delay time and the waiting time are configurable times.

[0018] The data prefetch time for sending / receiving starts at the Bluetooth transaction start time and ends at the transmit / receive radio frequency start time. The data prefetch time for sending / receiving is a configurable time.

[0019] The transmit / receive RF start time starts at the end of the transmit / receive data prefetch time and ends at the start of the transmit / receive data time. The transmit / receive RF start time is a configurable time.

[0020] The data transmission / reception time starts at the end of the data transmission / reception RF start time and ends at the start of the data transmission / reception RF shutdown time. The data transmission / reception time is determined based on the amount of data to be transmitted and received.

[0021] The transmit / receive radio frequency shutdown time starts at the end of the transmit / receive data time and ends at the start of the transmit / receive switching time interval. The transmit / receive radio frequency shutdown time is a configurable time.

[0022] The time gap for transmitting / receiving switching begins at the end of the transmit / receive RF shutdown time and ends at the start of the receive / transmit data prefetch time. The time gap for transmitting / receiving switching is the margin after removing other times from the master / slave mode operation cycle.

[0023] The receive / transmit data prefetch time starts at the end of the transmit / receive switching time gap and ends at the start of the receive / transmit RF start time. The receive / transmit data prefetch time is a configurable time.

[0024] The receive / transmit RF start time starts at the end of the receive / transmit data prefetch time and ends at the start of the receive / transmit data time. The receive / transmit RF start time is a configurable time.

[0025] The data receiving / transmission time starts at the end of the data receiving / transmission RF start time and ends at the start of the data receiving / transmission RF shutdown time. The data receiving / transmission time is determined based on the amount of data to be received and transmitted.

[0026] The receive / transmit radio frequency shutdown time starts at the end of the receive / transmit data time and ends at the end of the Bluetooth transaction. The receive / transmit radio frequency shutdown time is a configurable time.

[0027] The timing mechanism of this invention will be illustrated below with two specific examples.

[0028] The following examples are based on BR packets, but are not limited to BR transaction arrangements. Taking Bluetooth DM1 packets as an example, the ACCESS CODE of a DM1 packet is 72us, the HEADER is 54us, and the PAYLOAD is based on the longest possible length, consisting of an 8-bit PAYLOADHEADER, 17 bytes of data, a 16-bit CRC CODE, and a 32-bit MIC encrypted with AES-CCM. In addition to the ACCESS CODE and HEADER, other data also requires FEC operations. Therefore, the longest transmission or reception time for a DM1 packet is 72us + 54us + ((((1B + 17B + 2B + 4B) × 8 / 10) + 1) × 15)us = 426us.

[0029] In the Bluetooth protocol, the time unit for BR and EDR to send and receive data packets is a slot, and one slot is 625us.

[0030] In main mode, the Bluetooth module's local clock is the piconet clock. Assuming the Bluetooth module's clock is 0x200 in microseconds, the piconet clock is also 0x200 in microseconds, and the Bluetooth module's local clock and the piconet clock are aligned.

[0031] According to the timing mechanism of the present invention, the transmit / receive prefetch time is configured to be 80us, the transmit RF on time is 40us, the path delay is 5us, the waiting time is 5us, the transmit RF off time is 40us, the receive RF on time is 40us, and the receive RF off time is 40us.

[0032] If a DM1 data packet is seen in the air at piconet 0x300 (in microseconds), then calculating backwards, the hexadecimal data 0x300us is 768us in decimal. Subtracting the path delay of 5us, then the transmit RF activation time of 40us and the prefetch data time of 80us, we get 768 - 5 - 40 - 80 = 643us. This means the system needs to prepare all the data for the DM1 packet, including the access code, header, and payload, before the piconet time reaches 643us. Based on this calculation, the longest DM1 packet is 426us. Therefore, in a slot, besides the DM1 packet, there is 625 - 426 = 199us remaining. The Bluetooth module ends its DM1 packet transmission at 643+80+40+426+5+5=1199us. A 5us waiting time needs to be added. The Bluetooth module starts to shut down the radio frequency module from 1199us. It takes 40us to shut down, which is 1199+40=1239us. Only then does the Bluetooth module complete the first half of the transmission.

[0033] The subsequent packet reception also requires data prefetching. Since the DM1 packet is sent at 768µs, the time to receive the over-the-air response packet is 768 + 625 = 1393µs. Subtracting the waiting time of 5µs, then the receive RF activation time of 40µs and the data prefetching time of 80µs, we get 1393 - 5 - 40 - 80 = 1268µs. This means the system needs to prepare for packet reception before the piconet time reaches 1268µs. Assuming the received response packet is also the longest DM1 packet, the reception operation will complete at 1393 + 5 + 426 + 40 = 1864µs, requiring an additional 5µs path delay. After 1864µs, other Bluetooth tasks can be scheduled.

[0034] Therefore, the time interval between sending the DM1 packet and receiving the response packet is 1268-1239=29us.

[0035] According to the timing mechanism, 643us is the data prefetching point for sending the DM1 packet. Therefore, the data for the DM1 packet needs to be prepared at 643us of the piconet. At 1199us of the piconet, the transmission of the DM1 packet is completed, and the RF module is turned off. The Bluetooth module completes the transmission operation at 1239us of the piconet. After waiting for another 29us, the control signal for the receive response packet is prefetched at 1268us. Finally, the receive operation is completed at 1864us.

[0036] In slave mode, the Bluetooth piconet's clock is 0x1000 in microseconds (µs), while the Bluetooth module's local clock is 0x100 in µs. Therefore, the clock offset between the Bluetooth module and the piconet is 0xF00 in µs, with the piconet clock preceding the Bluetooth module's local clock. Subsequent calculations are based on the Bluetooth module's local clock, and a final 0xF00 clock offset is added to align with the Bluetooth piconet's clock.

[0037] According to the timing mechanism of the present invention, the transmit / receive prefetch time is configured to be 80µs, the transmit RF start time is 30µs, the path delay is 6µs, the waiting time is 6µs, the transmit RF stop time is 30µs, the receive RF start time is 30µs, and the receive RF stop time is 30µs.

[0038] If a DM1 data packet is received in the air at Bluetooth local clock time 0x300 (in microseconds), then calculating backwards, 0x300us in hexadecimal is 768us in decimal. First, subtract the waiting time of 6us, then subtract the receive RF activation time of 30us and the prefetch data time of 80us. 768 - 6 - 30 - 80 = 652us. This means the system needs to prepare to receive the data packet before Bluetooth local clock time reaches 652us. Based on this calculation, the longest DM1 packet is 426us. Therefore, in one slot, besides the DM1 packet, there is 625 - 426 = 199us remaining. The Bluetooth module's reception of the DM1 packet ends at 652 + 80 + 30 + 426 + 6 + 6 = 1200us. Adding a 6us path delay, the Bluetooth module begins to shut down the RF module from 1200us, which takes 30us. Therefore, at 1200 + 30 = 1230us, the Bluetooth module has completed the first half of the reception process.

[0039] Sending the DM1 packet also requires data prefetching. Since the DM1 packet is received at 768µs, the time to send the DM1 packet is 768 + 625 = 1393µs. Subtracting the path delay of 6µs, followed by the RF on-time of 30µs and the prefetch time of 80µs, we get 1393 - 6 - 30 - 80 = 1277µs. This means the system needs to prepare for packet transmission before the Bluetooth local clock reaches 1277µs. Assuming the transmitted packet is the longest DM1 packet, the transmission operation will complete at 1393 + 6 + 426 + 30 = 1855µs, requiring a 6µs wait time. After 1855µs, other Bluetooth tasks can be scheduled.

[0040] Therefore, the time interval between receiving a DM1 packet and sending a DM1 packet is 1277-1230=47us.

[0041] According to the timing mechanism, 652us is the data prefetch point for receiving the DM1 packet. When the Bluetooth local clock time is 1200us, the reception of the DM1 packet is completed, and the RF module is turned off. The Bluetooth module completes the reception operation at 1230us of the Bluetooth local clock. After waiting for another 47us, the control signal for sending the DM1 packet is prefetched at 1277us. Finally, the transmission operation is completed at 1855us.

[0042] It is important to note that in slave mode, there is an offset between the Bluetooth local clock and the Bluetooth piconet clock. Therefore, all calculated times need to be added to the offset to align with the Bluetooth piconet time.

Claims

1. A method for setting a Bluetooth communication transceiving packet time mechanism, used for BR and EDR transaction arrangement, characterized in that: The time mechanism is established based on the time interval of the Bluetooth piconet clock and different data packets, and includes a sending process and a receiving process, and is divided into a master mode and a slave mode, the master mode is to send data first and then receive data, and the slave mode is to receive data first and then send data; One sending process is a packet sending period, the packet sending period includes a packet sending time and a sending-receiving interval time, the packet sending period T1=n*625μs; one receiving process is a packet receiving period, the packet receiving period includes a packet receiving time and a receiving-sending interval time, the packet receiving period T2=n*625μs; according to the Bluetooth protocol, n∈[1,3,5] according to the type of packet; The master mode operation period T=T1+T2, the master mode operation period is sequentially set as a data sending pre-fetching time, a radio frequency sending starting time, a data sending time, a radio frequency sending closing time, a receiving-sending time interval, a data receiving pre-fetching time, a radio frequency receiving starting time, a data receiving time, and a radio frequency receiving closing time; The slave mode operation period T′=T1+T2, the slave mode operation period is sequentially set as a data receiving pre-fetching time, a radio frequency receiving starting time, a data receiving time, a radio frequency receiving closing time, a receiving-sending time interval, a data sending pre-fetching time, a radio frequency sending starting time, a data sending time, and a radio frequency sending closing time; The packet sending / receiving time corresponds to the data sending / receiving time; the start point of the packet sending / receiving time lags behind the start point of the data sending / receiving time, and the end point of the packet sending / receiving time is earlier than the end point of the data sending / receiving time; the start point of the packet sending time and the start point of the data sending time, and the end point of the packet receiving time and the end point of the data receiving time are path delay times, the start point of the packet receiving time and the start point of the data receiving time, and the end point of the packet sending time and the end point of the data sending time are waiting times, and the path delay times and the waiting times are configurable times.

2. The method according to claim 1, wherein: the data sending / receiving pre-fetching time starts at a Bluetooth transaction start time point and ends at a data sending / receiving radio frequency starting time start point, and is a configurable time; the data sending / receiving radio frequency starting time starts at the data sending / receiving pre-fetching time end point and ends at a data sending / receiving time start point, and is a configurable time; the data sending / receiving time starts at the data sending / receiving radio frequency starting time end point and ends at a data sending / receiving radio frequency closing time start point, and is determined according to the data sending / receiving amount; the data sending / receiving radio frequency closing time starts at the data sending / receiving time end point and ends at a receiving-sending time interval start point, and is a configurable time; the receiving-sending time interval starts at the data sending / receiving radio frequency closing time end point and ends at a data receiving / sending pre-fetching time start point, and is the remaining amount of the master / slave mode operation period after other times are removed. The receiving / sending data pre-fetch time starts from the end point of the time gap for transceiver switching and ends at the start point of the receiving / sending radio frequency start time, and the receiving / sending data pre-fetch time is a configurable time; The receiving / sending radio frequency start time starts from the end point of the receiving / sending data pre-fetch time and ends at the start point of the receiving / sending data time, and the receiving / sending radio frequency start time is a configurable time; The receiving / sending data time starts from the end point of the receiving / sending radio frequency start time and ends at the start point of the receiving / sending radio frequency close time, and the receiving / sending data time is determined according to the amount of transceiver data; The receiving / sending radio frequency close time starts from the end point of the receiving / sending data time and ends at the end point of the Bluetooth transaction, and the receiving / sending radio frequency close time is a configurable time.

Citation Information

Patent Citations

  • Bluetooth data transmission method and apparatus

    CN106559734A

  • Bluetooth master and slave equipment control method and device and Bluetooth equipment

    CN111107527A