bt spp 发送数据效率问题

lin_yi
Posts: 4
Joined: Fri Feb 03, 2023 9:54 am

bt spp 发送数据效率问题

Postby lin_yi » Fri Feb 03, 2023 9:59 am

一端使用 esp32 的 bt_spp_vfs_acceptor 文件的 write 循环发送,PC 端使用 socket recv 循环接收,接收速率只能达到 20kbytes/s, 如何提高速率?PC 端使用 socket 是否也是 SPP 协议?是否需要指定?谢谢。

ESP_Eavo
Posts: 186
Joined: Tue Jun 08, 2021 6:23 am

Re: bt spp 发送数据效率问题

Postby ESP_Eavo » Wed Feb 08, 2023 3:23 am

Q: How can we reach the maximum throughput when using SPP?
A: The default MTU size of classic Bluetooth SPP on ESP32 is 990 bytes, and higher throughput can be achieved in the case that data chunck size is close to the MTU size or multiple of MTU size. For example, sending 100 bytes data per second is much better than sending 10 bytes every 100 milliseconds.

Who is online

Users browsing this forum: No registered users and 12 guests