00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032 #ifndef __LWIP_OPT_H__
00033 #define __LWIP_OPT_H__
00034
00035 #include "lwip/debug.h"
00036
00037 #include "rtl_lwipopts.h"
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048 #ifndef SYS_LIGHTWEIGHT_PROT
00049 #define SYS_LIGHTWEIGHT_PROT 0
00050 #endif
00051
00052 #ifndef LWIP_PROVIDE_ERRNO
00053 #define LWIP_PROVIDE_ERRNO 1
00054 #endif
00055
00056 #ifndef NO_SYS
00057 #define NO_SYS 0
00058 #endif
00059
00060
00061
00062
00063
00064 #ifndef MEM_ALIGNMENT
00065 #define MEM_ALIGNMENT 1
00066 #endif
00067
00068
00069
00070 #ifndef MEM_SIZE
00071 #define MEM_SIZE 1600
00072 #endif
00073
00074
00075
00076
00077 #ifndef MEMP_NUM_PBUF
00078 #define MEMP_NUM_PBUF 16
00079 #endif
00080
00081
00082
00083 #ifndef MEMP_NUM_UDP_PCB
00084 #define MEMP_NUM_UDP_PCB 4
00085 #endif
00086
00087
00088 #ifndef MEMP_NUM_TCP_PCB
00089 #define MEMP_NUM_TCP_PCB 5
00090 #endif
00091
00092
00093 #ifndef MEMP_NUM_TCP_PCB_LISTEN
00094 #define MEMP_NUM_TCP_PCB_LISTEN 8
00095 #endif
00096
00097
00098 #ifndef MEMP_NUM_TCP_SEG
00099 #define MEMP_NUM_TCP_SEG 16
00100 #endif
00101
00102
00103 #ifndef MEMP_NUM_SYS_TIMEOUT
00104 #define MEMP_NUM_SYS_TIMEOUT 3
00105 #endif
00106
00107
00108
00109
00110 #ifndef MEMP_NUM_NETBUF
00111 #define MEMP_NUM_NETBUF 2
00112 #endif
00113
00114 #ifndef MEMP_NUM_NETCONN
00115 #define MEMP_NUM_NETCONN 4
00116 #endif
00117
00118
00119
00120 #ifndef MEMP_NUM_API_MSG
00121 #define MEMP_NUM_API_MSG 8
00122 #endif
00123
00124
00125
00126 #ifndef MEMP_NUM_TCPIP_MSG
00127 #define MEMP_NUM_TCPIP_MSG 8
00128 #endif
00129
00130
00131
00132
00133 #ifndef PBUF_POOL_SIZE
00134 #define PBUF_POOL_SIZE 16
00135 #endif
00136
00137
00138
00139 #ifndef PBUF_POOL_BUFSIZE
00140 #define PBUF_POOL_BUFSIZE 128
00141 #endif
00142
00143
00144
00145
00146 #ifndef PBUF_LINK_HLEN
00147 #define PBUF_LINK_HLEN 0
00148 #endif
00149
00150
00151
00152
00153
00155 #ifndef ARP_TABLE_SIZE
00156 #define ARP_TABLE_SIZE 10
00157 #endif
00158
00163 #ifndef ARP_QUEUEING
00164 #define ARP_QUEUEING 1
00165 #endif
00166
00172 #ifndef ETHARP_ALWAYS_INSERT
00173 #define ETHARP_ALWAYS_INSERT 1
00174 #endif
00175
00176
00177
00178
00179
00180 #ifndef IP_FORWARD
00181 #define IP_FORWARD 0
00182 #endif
00183
00184
00185
00186 #ifndef IP_OPTIONS
00187 #define IP_OPTIONS 1
00188 #endif
00189
00196 #ifndef IP_REASSEMBLY
00197 #define IP_REASSEMBLY 1
00198 #endif
00199
00201 #ifndef IP_FRAG
00202 #define IP_FRAG 1
00203 #endif
00204
00205
00206
00207 #ifndef ICMP_TTL
00208 #define ICMP_TTL 255
00209 #endif
00210
00211
00212
00213 #ifndef LWIP_DHCP
00214 #define LWIP_DHCP 0
00215 #endif
00216
00217
00218
00219 #ifndef DHCP_DOES_ARP_CHECK
00220 #define DHCP_DOES_ARP_CHECK 1
00221 #endif
00222
00223
00224 #ifndef LWIP_UDP
00225 #define LWIP_UDP 1
00226 #endif
00227
00228 #ifndef UDP_TTL
00229 #define UDP_TTL 255
00230 #endif
00231
00232
00233 #ifndef LWIP_TCP
00234 #define LWIP_TCP 1
00235 #endif
00236
00237 #ifndef TCP_TTL
00238 #define TCP_TTL 255
00239 #endif
00240
00241 #ifndef TCP_WND
00242 #define TCP_WND 2048
00243 #endif
00244
00245 #ifndef TCP_MAXRTX
00246 #define TCP_MAXRTX 12
00247 #endif
00248
00249 #ifndef TCP_SYNMAXRTX
00250 #define TCP_SYNMAXRTX 6
00251 #endif
00252
00253
00254
00255
00256 #ifndef TCP_QUEUE_OOSEQ
00257 #define TCP_QUEUE_OOSEQ 1
00258 #endif
00259
00260
00261 #ifndef TCP_MSS
00262 #define TCP_MSS 128
00263 #endif
00264
00265
00266 #ifndef TCP_SND_BUF
00267 #define TCP_SND_BUF 256
00268 #endif
00269
00270
00271
00272 #ifndef TCP_SND_QUEUELEN
00273 #define TCP_SND_QUEUELEN 4 * TCP_SND_BUF/TCP_MSS
00274 #endif
00275
00276
00277
00278
00279
00280
00281
00282
00283
00284 #ifndef TCP_SNDLOWAT
00285 #define TCP_SNDLOWAT TCP_SND_BUF/2
00286 #endif
00287
00288
00289
00290
00291 #ifndef LWIP_EVENT_API
00292 #define LWIP_EVENT_API 0
00293 #define LWIP_CALLBACK_API 1
00294 #else
00295 #define LWIP_EVENT_API 1
00296 #define LWIP_CALLBACK_API 0
00297 #endif
00298
00299 #ifndef LWIP_COMPAT_SOCKETS
00300 #define LWIP_COMPAT_SOCKETS 1
00301 #endif
00302
00303
00304 #ifndef TCPIP_THREAD_PRIO
00305 #define TCPIP_THREAD_PRIO 1
00306 #endif
00307
00308 #ifndef SLIPIF_THREAD_PRIO
00309 #define SLIPIF_THREAD_PRIO 1
00310 #endif
00311
00312 #ifndef PPP_THREAD_PRIO
00313 #define PPP_THREAD_PRIO 1
00314 #endif
00315
00316 #ifndef DEFAULT_THREAD_PRIO
00317 #define DEFAULT_THREAD_PRIO 1
00318 #endif
00319
00320 #ifndef LWIP_STATS
00321 #define LWIP_STATS 1
00322 #endif
00323
00324 #if LWIP_STATS
00325
00326 #define LINK_STATS
00327 #define IP_STATS
00328 #define ICMP_STATS
00329 #define UDP_STATS
00330 #define TCP_STATS
00331 #define MEM_STATS
00332 #define MEMP_STATS
00333 #define PBUF_STATS
00334 #define SYS_STATS
00335
00336 #endif
00337
00338
00339
00340 #ifndef PPP_SUPPORT
00341 #define PPP_SUPPORT 0
00342 #endif
00343
00344 #if PPP_SUPPORT
00345
00346 #define NUM_PPP 1
00347
00348
00349
00350 #ifndef PAP_SUPPORT
00351 #define PAP_SUPPORT 0
00352 #endif
00353
00354 #ifndef CHAP_SUPPORT
00355 #define CHAP_SUPPORT 0
00356 #endif
00357
00358 #define MSCHAP_SUPPORT 0
00359 #define CBCP_SUPPORT 0
00360 #define CCP_SUPPORT 0
00361
00362 #ifndef VJ_SUPPORT
00363 #define VJ_SUPPORT 0
00364 #endif
00365
00366 #ifndef MD5_SUPPORT
00367 #define MD5_SUPPORT 0
00368 #endif
00369
00370
00371
00372
00373
00374 #define FSM_DEFTIMEOUT 6
00375 #define FSM_DEFMAXTERMREQS 2
00376 #define FSM_DEFMAXCONFREQS 10
00377 #define FSM_DEFMAXNAKLOOPS 5
00378
00379 #define UPAP_DEFTIMEOUT 6
00380 #define UPAP_DEFREQTIME 30
00381
00382 #define CHAP_DEFTIMEOUT 6
00383 #define CHAP_DEFTRANSMITS 10
00384
00385
00386
00387 #if 1
00388 #define LCP_ECHOINTERVAL 0
00389 #else
00390 #define LCP_ECHOINTERVAL 10
00391 #endif
00392
00393
00394 #define LCP_MAXECHOFAILS 3
00395
00396
00397 #define PPP_MAXIDLEFLAG 100
00398
00399
00400
00401
00402
00403
00404
00405
00406
00407 #define PPP_MTU 1500
00408 #if 0
00409 #define PPP_MAXMTU 65535 - (PPP_HDRLEN + PPP_FCSLEN)
00410 #else
00411 #define PPP_MAXMTU 1500
00412 #endif
00413 #define PPP_MINMTU 64
00414 #define PPP_MRU 1500
00415 #define PPP_MAXMRU 1500
00416 #define PPP_DEFMRU 296
00417 #define PPP_MINMRU 128
00418
00419
00420 #define MAXNAMELEN 256
00421 #define MAXSECRETLEN 256
00422
00423 #endif
00424
00425
00426
00427
00428 #ifndef DBG_TYPES_ON
00429 #define DBG_TYPES_ON 0
00430 #endif
00431
00432 #ifndef DEMO_DEBUG
00433 #define DEMO_DEBUG DBG_OFF
00434 #endif
00435
00436 #ifndef ETHARP_DEBUG
00437 #define ETHARP_DEBUG DBG_OFF
00438 #endif
00439
00440 #ifndef NETIF_DEBUG
00441 #define NETIF_DEBUG DBG_OFF
00442 #endif
00443
00444 #ifndef PBUF_DEBUG
00445 #define PBUF_DEBUG DBG_OFF
00446 #endif
00447
00448 #ifndef API_LIB_DEBUG
00449 #define API_LIB_DEBUG DBG_OFF
00450 #endif
00451
00452 #ifndef API_MSG_DEBUG
00453 #define API_MSG_DEBUG DBG_OFF
00454 #endif
00455
00456 #ifndef SOCKETS_DEBUG
00457 #define SOCKETS_DEBUG DBG_OFF
00458 #endif
00459
00460 #ifndef ICMP_DEBUG
00461 #define ICMP_DEBUG DBG_ON
00462 #endif
00463
00464 #ifndef INET_DEBUG
00465 #define INET_DEBUG DBG_OFF
00466 #endif
00467
00468 #ifndef IP_DEBUG
00469 #define IP_DEBUG DBG_OFF
00470 #endif
00471
00472 #ifndef IP_REASS_DEBUG
00473 #define IP_REASS_DEBUG DBG_OFF
00474 #endif
00475
00476 #ifndef MEM_DEBUG
00477 #define MEM_DEBUG DBG_OFF
00478 #endif
00479
00480 #ifndef MEMP_DEBUG
00481 #define MEMP_DEBUG DBG_OFF
00482 #endif
00483
00484 #ifndef SYS_DEBUG
00485 #define SYS_DEBUG DBG_OFF
00486 #endif
00487
00488 #ifndef TCP_DEBUG
00489 #define TCP_DEBUG DBG_OFF
00490 #endif
00491
00492 #ifndef TCP_INPUT_DEBUG
00493 #define TCP_INPUT_DEBUG DBG_OFF
00494 #endif
00495
00496 #ifndef TCP_FR_DEBUG
00497 #define TCP_FR_DEBUG DBG_OFF
00498 #endif
00499
00500 #ifndef TCP_RTO_DEBUG
00501 #define TCP_RTO_DEBUG DBG_OFF
00502 #endif
00503
00504 #ifndef TCP_REXMIT_DEBUG
00505 #define TCP_REXMIT_DEBUG DBG_OFF
00506 #endif
00507
00508 #ifndef TCP_CWND_DEBUG
00509 #define TCP_CWND_DEBUG DBG_OFF
00510 #endif
00511
00512 #ifndef TCP_WND_DEBUG
00513 #define TCP_WND_DEBUG DBG_OFF
00514 #endif
00515
00516 #ifndef TCP_OUTPUT_DEBUG
00517 #define TCP_OUTPUT_DEBUG DBG_OFF
00518 #endif
00519
00520 #ifndef TCP_RST_DEBUG
00521 #define TCP_RST_DEBUG DBG_OFF
00522 #endif
00523
00524 #ifndef TCP_QLEN_DEBUG
00525 #define TCP_QLEN_DEBUG DBG_OFF
00526 #endif
00527
00528 #ifndef UDP_DEBUG
00529 #define UDP_DEBUG DBG_OFF
00530 #endif
00531
00532 #ifndef TCPIP_DEBUG
00533 #define TCPIP_DEBUG DBG_OFF
00534 #endif
00535
00536 #ifndef SLIP_DEBUG
00537 #define SLIP_DEBUG DBG_OFF
00538 #endif
00539
00540 #ifndef DHCP_DEBUG
00541 #define DHCP_DEBUG DBG_OFF
00542 #endif
00543
00544
00545 #ifndef DBG_MIN_LEVEL
00546 #define DBG_MIN_LEVEL DBG_LEVEL_OFF
00547 #endif
00548
00549 #endif
00550
00551
00552