Improve UDP RCVBUF configuration

This commit is contained in:
2020-05-11 17:49:13 +02:00
parent 82dce2b9a0
commit 6af37e927d
+5 -2
View File
@@ -34,8 +34,11 @@ namespace core_buffer {
// Time to sleep before retrying to read the queue.
const size_t BUFFER_QUEUE_RETRY_MS = 5;
// Size of UDP recv buffer.
const int BUFFER_UDP_RCVBUF = MODULE_N_BYTES * 10;
// Size of UDP recv buffer
const int BUFFER_UDP_RCVBUF_N_SLOTS = 10;
// +1 for packet headers.
const int BUFFER_UDP_RCVBUF_BYTES = (
MODULE_N_BYTES * (BUFFER_UDP_RCVBUF_N_SLOTS + 1));
// Microseconds timeout for UDP recv.
const int BUFFER_UDP_US_TIMEOUT = 5 * 1000;