当前位置:网站首页>Bluetooth gap protocol
Bluetooth gap protocol
2022-08-05 07:05:00 【aningxiaoxixi】
**
Datagram **
(It is defined by the gap layer starting from advdata in the payload, and it was defined by the ll layer before)
pdu type Data type transmitted
0 Normal broadcast data
1 Directional broadcast data (data is transmitted to a specified device)
2 Unconnectable broadcast data
Payload format analysis
adva indicates the address of the broadcaster
advdata broadcaster data
Indicates data type in data
0 limited discovery mode
1 general discovery mode
From the above table, the physical layer table can be seen
The broadcaster must have the sending attribute (which can be understood as having a transmitter)
The observer must have the receiving attribute (which can be understood as having a receiver)
The central device and the peripheral device must have the sending attribute and the receiving attribute
Broadcast event
Non-connectable and non-scannable undirected event
Non-connectable, unscannable, undirected event
Procedure
There are 2 methods for observation procedure
1 Active scan:
Observer notifies broadcaster first, then scans broadcaster
2 Passive scan:
Observers just scan for broadcasters
Modes and Procedures
Divided into
1 Undiscoverable mode
2 Restricted discoverable mode
3 Normal discoverable mode
Connection modes and procedures
Non-Connectable Mode
Non-Connectable ModeDirected Connectable Mode
Directed Connectable Mode, which
peripherals can use if they want to quickly connect to the central device.
In this mode, it sends out the ADV_DIRECT_ADV broadcast message directly to the designated central device.
Therefore, the peripheral device should have established a connection with the central device.
The sending frequency of ADV_DIRECT_ADV broadcast messages is very fast. This mode lasts for 1.28S at most, after which the controller automatically stops broadcasting.Undirected Connectable Mode
Undirected Connectable Mode.
Use this mode if a peripheral device does not need to establish a connection quickly, or if you intend to save as much power as possible.
It sends out the ADV_IND broadcast message.Auto Connection Establishment Procedure
Auto Connection Establishment Procedure.
This procedure is used by the central device to set up the controller to automatically establish a connection to one or more peripheral devices.The Host needs to write the device to be connected to the "whitelist" in advance.
It has a disadvantage: only one basic set of connection parameters can be used for all devices.General Connection Establishment Procedure
The general connection establishment procedure.
This is our commonly used procedure, first scan out the device, select a certain one, and then use the "Direct Connection Establishment Procedure" to connect it.Selective Connection Establishment Procedure
Selective Connection Establishment Procedure.
The Host first puts the device to be connected into the "whitelist" of the Controller.Devices that are broadcasting, only those on the whitelist will be submitted to the host.
The Host decides whether to connect the device and uses different parameters to connect it.Compared to the "automatic connection establishment procedure", the "selective connection establishment procedure" can use different parameters to connect each device.Direct Connection Establishment Procedure
Direct Connection Establishment Procedure, direct connection to the specified device.Connection Parameter Update Procedure
Connection parameter update procedure.Terminate Connection Procedure
Terminate the connection procedure.
Central equipment or peripheral equipment can execute this procedure, just send LL_TERMINATE_IND PDU to each other through LL layer.
边栏推荐
猜你喜欢
随机推荐
PCI Pharma Services宣布斥资数百万美元扩建英国制造设施,以满足市场对支持肿瘤治疗的全球高效药制造服务日益增长的需求
铠侠携手Aerospike提升数据库应用性能
uniapp打包次数限制怎么办?只需两步就能解决
(2022杭电多校六)1012-Loop(单调栈+思维)
Source code analysis of Nacos configuration service (full)
文本样式这一篇文章就够了
【instancetype类型 Objective-C】
DNSlog外带数据注入
Mysql主从延迟的原因和解决方案
ndk编译so库
LaTeX Notes
typescript63-索引签名类型
关于Antd的Affix突然不好用了,或者Window的scroll监听不好用了
(4) Rotating object detection data roLabelImg to DOTA format
DevExpress中针对指定列进行百分比转换
Shared memory + inotify mechanism to achieve multi-process low-latency data sharing
typescript68-索引查询类型(查询多个)
Japan Sanitary Equipment Industry Association: Japan's warm water shower toilet seat shipments reached 100 million sets
Jenkins详细配置
Get the network input dimensions of the pretrained model









