当前位置:网站首页>Bluetooth (5) -- about retransmission
Bluetooth (5) -- about retransmission
2022-06-11 00:08:00 【yuanyun_ elber】
Finally, it comes to l2cap The layer .
L2CAP Features include agreement / Channel multiplexing , Regroup in sections (segmentation and reassembly, SAR), Flow control and error control of each channel
The channel here does not refer to the physical channel of different frequency bands , But to l2cap The layer is open to the upper application channel, The upper application is based on l2cap Layer of channel id To judge whether it belongs to you profile Of data Of .
Let's continue with the topic that we didn't finish last time .
In most cases , Yes hci Layer flow control is enough , But somehow l2cap It provides this service , It is always right for us to study .
L2cap The logical channel of can work in 5 In different modes ( It can be understood as 5 Different scenarios )
1、Basic L2CAP Mode(equivalent to L2CAP specification in Bluetooth v1.1) The default mode , When no other mode is selected , In this mode .
2、Flow Control Mode In this mode, retransmission will not be performed , But missing data can be detected , And report loss .
3、Retransmission Mode This mode ensures that all data packets can be successfully transmitted to the peer device .
4、Enhanced Retransmission Mode This mode is similar to the retransmission mode , Joined the Poll-bit And so on .
5、Streaming Mode This mode is for real-time transmission , Packets are numbered but do not need to ACK confirm . Set a timeout timer , Once the timer times out, the timeout data will be flushed .
6、LE Credit Based Flow Control Mode Be used for LE Device communication .
Generally speaking , We work in the first mode , In this mode ,l2cap The layer has no flow control and retransmission .
The retransmission of Bluetooth is actually LC The floor already has , adopt ARQ, It's basically a question and answer form .
L2cap Layer retransmission should be discussed together with flow control , stay flow control mode and retransmission mode Next , There is a kind of s-frame Special package for , Which includes seq number Information about ( Be careful , stay lc Layer provides seq, Only 0 and 1 Two kinds of , because lc Layer of arq The mechanism is strictly a question and answer , therefore seq Only 0 and 1 That's enough )
L2cap The layers are a little different , You can set a tx window, After sending multiple packets continuously , Then ask the other party to answer , The benefit of this is the improvement of efficiency .
The following is the sequence diagram of retransmission mode :

The difference between flow control mode and retransmission mode is , No retransmission in flow control mode , But it will report packet loss .
Review flow control and retransmission :
Bluetooth retransmission and flow control in general LC Layers are fine cover,l2cap Although the layer provides related services , But it is seldom used in practical applications . about LC Layer , Retransmission based on ARQ Mechanism , Flow control depends on controller buffe, from LC Layer update packet header Medium flow position . in addition , For the local hci transport Interface , There are two types of flow control , One is hci command, adopt hci command complete event Flow control , General controller Only single command is supported ; Two is hci acl data, There are two directions of flow control , adopt hci read buffer size command,hci host buffer size command,hci host number of completed packets command,hci number of completed packets event Four orders 、 Event flow control .
边栏推荐
- 【Pygame小游戏】“史上最炫酷贪吃蛇”驾到,FUN开玩(不好玩不要钱)
- How to handle the database query error with Emoji expression in Typecho- Xingze V Club
- In the month of safety production, Huangpu launched a publicity campaign for gas safety in shops
- LabVIEW determines the position of the control in the display coordinate system
- [pyGame games] don't look for it. Here comes the leisure game topic - bubble dragon widget - recommendation for leisure game research and development
- 示波器和频谱分析仪的区别
- Serial port missing in Ni Max in LabVIEW
- 【Pygame合集】滴~穿越童年游戏指南 请查收:这里面有你玩过的游戏嘛?(附五款源码自取)
- Is it safe for changtou school to open an account? Is it reliable?
- [appearance detection artifact] come on, please show me your unique skill (is this appearance worthy of the audience?)
猜你喜欢
![[pyGame games] story stream recommendation: what kind of games can you like? (devil lover, bully's wife version)](/img/77/653968895434f805d81a10406dcf6f.png)
[pyGame games] story stream recommendation: what kind of games can you like? (devil lover, bully's wife version)

Easyrecovery15 simple and convenient data recovery tool

【自动回复小脚本】新年快乐,每一个字都是我亲自手打的,不是转发哦~

Self made app connected to onenet --- realize data monitoring and distribution control (mqtt)

Difference between oscilloscope and spectrum analyzer

IGBT与三代半导体SiC双脉冲测试方案

LabVIEW performs a serial loopback test

LabVIEW 禁止其他可多核心处理的应用程序在所有核心上执行
![[pyGame] when the](/img/7e/d2cd2eb2fff2c1fb2b41f579d4f70e.png)
[pyGame] when the "coolest snake in history" arrives, fun will play it (no money for fun)
![[turtle confessions collection]](/img/97/6f1008386931bcb93655d94121e2c4.png)
[turtle confessions collection] "the moon at the bottom of the sea is the moon in the sky, and the person in front of us is the sweetheart." Be happy for the rest of your life, and be safe for ever ~
随机推荐
CSDN daily practice - find the closest element and output the subscript
Baidu quick collection SEO optimization keyword ranking optimization skills
Openresty installation
LabVIEW programming specification
[pyGame] this classic bomber super game is online. Do you love it? (source code attached)
LabVIEW改变Point ROI Overlay的形状或颜色
Struggle, programmer -- Chapter 56: hard work with thousands of blows
关于优化API接口响应速度
Go语言Channel理解使用
Error report of curl import postman
[turtle confessions collection] "the moon at the bottom of the sea is the moon in the sky, and the person in front of us is the sweetheart." Be happy for the rest of your life, and be safe for ever ~
Method of converting file to multipartfile
LabVIEW pictures look bright or dark after being cast from 16 bits to 8 bits
LabVIEW 禁止其他可多核心处理的应用程序在所有核心上执行
【自动回复or提醒小助手】妈妈再也不用担心我漏掉消息了(10行代码系列)
High speed data stream disk for LabVIEW
Why is the website snapshot hijacked and tampered with
插入排序
安全生产月,黄埔开展燃气安全进商铺宣传活动
[auto reply or remind assistant] Mom doesn't have to worry about me missing messages any more (10 Line Code Series)