FLIR Knowledge Base
Search for...
Search
        |     
Exclude unwanted words:
Browse KB Articles
Go Back Printable Version Email This Article Bookmark This Article

Lost Ethernet data packets on Linux systems using FlyCapture2

KB Number: 10016
Last Revision Date: 6/7/2016

This article provides possible solutions to lost data packets when streaming images from a GigE Vision camera on Linux Ubuntu 8.04 or newer systems when using FlyCapture2 API. 

CAUSE:
When streaming images from a GigE Vision camera on Linux Ubuntu 8.04 systems, a high number of lost data packets may be observed. In FlyCapture SDK applications, dropped packets result in IMAGE_CONSISTENCY_ERRORS returned.

ANSWER:

To fix, try one or both of the following:

  • Increase packet delay time using the FlyCapture2 API or the FlyCap2 program.
  • Increase the amount of memory Linux uses for receive buffers using the sysctl interface. Whereas the system standard (default) and maximum values for this buffer default to 128 KB and 120 KB respectively, increasing both of these parameters to 1 MB significantly improves image streaming results.

Note: On some ARM boards, you may need to increase the receive buffer size to greater than 1 MB before noticing improved streaming results. Increasing the buffer size can enhance receive performance, but it also uses more memory.

The following sysctl command updates the receive buffer memory settings:

sudo sysctl -w net.core.rmem_max=1048576 net.core.rmem_default=1048576

Note: In order for these changes to persist after system reboots, the following lines must be manually added to the bottom of the /etc/sysctl.conf file:

net.core.rmem_max=1048576
net.core.rmem_default=1048576

Once changes are persisted, they can be reloaded at any time by running the following command in sysctl:

sudo sysctl -p

Was this article helpful?

Go Back Printable Version Email This Article Bookmark This Article