0

I am building an embedded device that runs Linux (Armbian) and receives a steady stream of UDP data. It has both Ethernet and WiFi connectivity. Ethernet works fine, however when using WiFi, the data stream will occasionally appear to suddenly pause for up to a second, no data is received during this period. The packets are not lost, however, they seem to just be queued in the network driver stack somewhere. And after the pause is up, the entire backlog is dumped on the application.

This would be fine if I had a reasonable buffer to work with, but my stream is very time-sensitive, I cannot afford jitter more than 50ms or so. So these pauses lead to big buffer underruns in my application.

The delay is at the receiver, earlier than userspace, since tshark running there shows a gap in packets when it happens. But this gap is not present in wireshark on the client PC. It is hard to tell whether the spikes correlate with activity, since activity is very evenly distributed on the device, there is nothing else of note running on there than my application. It is not correlated with time, it seems random.

Where can I begin to troubleshoot this?

4
  • 1
    Install wireshark and look at the timing of the packets going across the wire. Is the delay at the transmitter or receiver? Do the "spikes" correlate with system activity? Time? Commented Jul 18 at 23:43
  • @waltinator The delay is at the receiver, earlier than userspace, since tshark running there shows a gap in packets when it happens. But this gap is not present in wireshark on the client PC. It is hard to tell whether the spikes correlate with activity, since activity is very evenly distributed on the device, there is nothing else of note running on there than my application. It is not correlated with time, it seems random. Commented Jul 20 at 12:59
  • 2
    Comments are designed for us to ask you questions about your Question. Please Edit your question rather than replying in comments. How to Ask a new question if you have a new problem. Commented Jul 20 at 18:02
  • 1
    @GrixM I would guess power saving at either end - the transmitter shuts down to save power. This may be at either end, as it would occur after packets have left the TCP/IP stack, and handed over to the driver - so I believe you would not see it using wireshark. It may also be interference or similar; guaranteeing realtime over wifi is not easy. Commented Jul 23 at 9:24

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.