Hi Mathias, On Tue, Jul 2, 2019 at 3:33 PM Mathias Baert <mathiasrobaert@xxxxxxxxx> wrote: > > Hi, > > We are using the BlueZ 5.48 version on a Raspberry PI with Raspbian Stretch 9.1. > > The setup is this PI connected with a Nordic Semiconductor nRF52840 > device, via an IPv6 over BLE connection. The connection is using a > connection interval of 7.5 ms. Via throughput measurements with iperf, > both ways (central to peripheral and peripheral to central), we are > able to achieve maximally ~ 100 kbps (using the 1 Mbps PHY). > > However, when looking into individual packet exchanges, we notice a > significant delay (up to 1 sec) in the RTT when pinging from the > peripheral to the BlueZ central and back. We also see a huge > fluctuation in this value and it also depends on the intervals at > which the pings are fired (lower throughput gives a much higher > average individual latency). When firing ping packets at a 1 sec > interval, it is definitely visible. > > When looking into this, we found that the latency between the > peripheral and the central is quite stable and low enough. But the > latency between the central and peripheral is fluctuating a lot and is > generally quite high. Is this something you have noticed before? We > think that it could be a scheduling issue on the kernel, where higher > throughput gives more priority to Bluetooth communication? So I assume this is using the experimental IPSP support with Zephyr as peripheral? Usually, the Linux side is quite a bit more complex so it is not surprising it can take more time but not 1 sec. so it got to be something that is causing the extra lag, perhaps you can paste the actual commands you are using to ping one another. -- Luiz Augusto von Dentz