2013-08-15 10:17:15 +02:00
|
|
|
/*
|
2014-01-31 15:06:01 +01:00
|
|
|
* Copyright (C) 2013 Freie Universität Berlin.
|
2013-08-15 10:17:15 +02:00
|
|
|
*
|
2014-08-23 15:43:13 +02:00
|
|
|
* This file is subject to the terms and conditions of the GNU Lesser
|
|
|
|
* General Public License v2.1. See the file LICENSE in the top level
|
|
|
|
* directory for more details.
|
2014-01-31 15:06:01 +01:00
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @{
|
|
|
|
* @file tcp_timer.h
|
|
|
|
* @author Oliver Gesch <oliver.gesch@googlemail.com>
|
2013-08-15 10:17:15 +02:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef TCP_TIMER_H_
|
|
|
|
#define TCP_TIMER_H_
|
|
|
|
|
2014-10-10 11:51:11 +02:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2014-07-31 20:51:50 +02:00
|
|
|
#define TCP_TIMER_RESOLUTION 500*1000
|
|
|
|
|
|
|
|
#define SECOND 1000.0f*1000.0f
|
|
|
|
#define TCP_TIMER_STACKSIZE KERNEL_CONF_STACKSIZE_DEFAULT
|
|
|
|
#define TCP_SYN_INITIAL_TIMEOUT 6*SECOND
|
|
|
|
#define TCP_SYN_TIMEOUT 24*SECOND
|
|
|
|
#define TCP_MAX_SYN_RETRIES 3
|
|
|
|
#define TCP_INITIAL_ACK_TIMEOUT 3.0f*SECOND // still static, should be calculated via RTT
|
|
|
|
#define TCP_ACK_MAX_TIMEOUT 30*SECOND // TODO: Set back to 90 Seconds
|
|
|
|
|
|
|
|
#define TCP_ALPHA 1.0f/8.0f
|
|
|
|
#define TCP_BETA 1.0f/4.0f
|
|
|
|
|
|
|
|
#define TCP_NOT_DEFINED 0
|
|
|
|
#define TCP_RETRY 1
|
|
|
|
#define TCP_TIMEOUT 2
|
|
|
|
#define TCP_CONTINUE 3
|
2013-08-15 10:17:15 +02:00
|
|
|
|
2014-03-04 20:20:01 +01:00
|
|
|
void *tcp_general_timer(void *);
|
2013-08-15 10:17:15 +02:00
|
|
|
|
2014-10-10 11:51:11 +02:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2013-08-15 10:17:15 +02:00
|
|
|
#endif /* TCP_TIMER_H_ */
|
2014-01-31 15:06:01 +01:00
|
|
|
/**
|
|
|
|
* @}
|
|
|
|
*/
|