Onenet
Dependents: K64F_eCompass_OneNET_JW
lwip/include/lwip/opt.h@0:b2805b6888dc, 2016-06-20 (annotated)
- Committer:
- robert_jw
- Date:
- Mon Jun 20 01:40:20 2016 +0000
- Revision:
- 0:b2805b6888dc
ADS
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
robert_jw | 0:b2805b6888dc | 1 | /** |
robert_jw | 0:b2805b6888dc | 2 | * @file |
robert_jw | 0:b2805b6888dc | 3 | * |
robert_jw | 0:b2805b6888dc | 4 | * lwIP Options Configuration |
robert_jw | 0:b2805b6888dc | 5 | */ |
robert_jw | 0:b2805b6888dc | 6 | |
robert_jw | 0:b2805b6888dc | 7 | /* |
robert_jw | 0:b2805b6888dc | 8 | * Copyright (c) 2001-2004 Swedish Institute of Computer Science. |
robert_jw | 0:b2805b6888dc | 9 | * All rights reserved. |
robert_jw | 0:b2805b6888dc | 10 | * |
robert_jw | 0:b2805b6888dc | 11 | * Redistribution and use in source and binary forms, with or without modification, |
robert_jw | 0:b2805b6888dc | 12 | * are permitted provided that the following conditions are met: |
robert_jw | 0:b2805b6888dc | 13 | * |
robert_jw | 0:b2805b6888dc | 14 | * 1. Redistributions of source code must retain the above copyright notice, |
robert_jw | 0:b2805b6888dc | 15 | * this list of conditions and the following disclaimer. |
robert_jw | 0:b2805b6888dc | 16 | * 2. Redistributions in binary form must reproduce the above copyright notice, |
robert_jw | 0:b2805b6888dc | 17 | * this list of conditions and the following disclaimer in the documentation |
robert_jw | 0:b2805b6888dc | 18 | * and/or other materials provided with the distribution. |
robert_jw | 0:b2805b6888dc | 19 | * 3. The name of the author may not be used to endorse or promote products |
robert_jw | 0:b2805b6888dc | 20 | * derived from this software without specific prior written permission. |
robert_jw | 0:b2805b6888dc | 21 | * |
robert_jw | 0:b2805b6888dc | 22 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED |
robert_jw | 0:b2805b6888dc | 23 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
robert_jw | 0:b2805b6888dc | 24 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT |
robert_jw | 0:b2805b6888dc | 25 | * SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, |
robert_jw | 0:b2805b6888dc | 26 | * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT |
robert_jw | 0:b2805b6888dc | 27 | * OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS |
robert_jw | 0:b2805b6888dc | 28 | * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN |
robert_jw | 0:b2805b6888dc | 29 | * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING |
robert_jw | 0:b2805b6888dc | 30 | * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY |
robert_jw | 0:b2805b6888dc | 31 | * OF SUCH DAMAGE. |
robert_jw | 0:b2805b6888dc | 32 | * |
robert_jw | 0:b2805b6888dc | 33 | * This file is part of the lwIP TCP/IP stack. |
robert_jw | 0:b2805b6888dc | 34 | * |
robert_jw | 0:b2805b6888dc | 35 | * Author: Adam Dunkels <adam@sics.se> |
robert_jw | 0:b2805b6888dc | 36 | * |
robert_jw | 0:b2805b6888dc | 37 | */ |
robert_jw | 0:b2805b6888dc | 38 | #ifndef __LWIP_OPT_H__ |
robert_jw | 0:b2805b6888dc | 39 | #define __LWIP_OPT_H__ |
robert_jw | 0:b2805b6888dc | 40 | |
robert_jw | 0:b2805b6888dc | 41 | /* |
robert_jw | 0:b2805b6888dc | 42 | * Include user defined options first. Anything not defined in these files |
robert_jw | 0:b2805b6888dc | 43 | * will be set to standard values. Override anything you dont like! |
robert_jw | 0:b2805b6888dc | 44 | */ |
robert_jw | 0:b2805b6888dc | 45 | #include "lwipopts.h" |
robert_jw | 0:b2805b6888dc | 46 | #include "lwip/debug.h" |
robert_jw | 0:b2805b6888dc | 47 | |
robert_jw | 0:b2805b6888dc | 48 | /* |
robert_jw | 0:b2805b6888dc | 49 | ----------------------------------------------- |
robert_jw | 0:b2805b6888dc | 50 | ---------- Platform specific locking ---------- |
robert_jw | 0:b2805b6888dc | 51 | ----------------------------------------------- |
robert_jw | 0:b2805b6888dc | 52 | */ |
robert_jw | 0:b2805b6888dc | 53 | |
robert_jw | 0:b2805b6888dc | 54 | /** |
robert_jw | 0:b2805b6888dc | 55 | * SYS_LIGHTWEIGHT_PROT==1: if you want inter-task protection for certain |
robert_jw | 0:b2805b6888dc | 56 | * critical regions during buffer allocation, deallocation and memory |
robert_jw | 0:b2805b6888dc | 57 | * allocation and deallocation. |
robert_jw | 0:b2805b6888dc | 58 | */ |
robert_jw | 0:b2805b6888dc | 59 | #ifndef SYS_LIGHTWEIGHT_PROT |
robert_jw | 0:b2805b6888dc | 60 | #define SYS_LIGHTWEIGHT_PROT 0 |
robert_jw | 0:b2805b6888dc | 61 | #endif |
robert_jw | 0:b2805b6888dc | 62 | |
robert_jw | 0:b2805b6888dc | 63 | /** |
robert_jw | 0:b2805b6888dc | 64 | * NO_SYS==1: Provides VERY minimal functionality. Otherwise, |
robert_jw | 0:b2805b6888dc | 65 | * use lwIP facilities. |
robert_jw | 0:b2805b6888dc | 66 | */ |
robert_jw | 0:b2805b6888dc | 67 | #ifndef NO_SYS |
robert_jw | 0:b2805b6888dc | 68 | #define NO_SYS 0 |
robert_jw | 0:b2805b6888dc | 69 | #endif |
robert_jw | 0:b2805b6888dc | 70 | |
robert_jw | 0:b2805b6888dc | 71 | /** |
robert_jw | 0:b2805b6888dc | 72 | * NO_SYS_NO_TIMERS==1: Drop support for sys_timeout when NO_SYS==1 |
robert_jw | 0:b2805b6888dc | 73 | * Mainly for compatibility to old versions. |
robert_jw | 0:b2805b6888dc | 74 | */ |
robert_jw | 0:b2805b6888dc | 75 | #ifndef NO_SYS_NO_TIMERS |
robert_jw | 0:b2805b6888dc | 76 | #define NO_SYS_NO_TIMERS 0 |
robert_jw | 0:b2805b6888dc | 77 | #endif |
robert_jw | 0:b2805b6888dc | 78 | |
robert_jw | 0:b2805b6888dc | 79 | /** |
robert_jw | 0:b2805b6888dc | 80 | * MEMCPY: override this if you have a faster implementation at hand than the |
robert_jw | 0:b2805b6888dc | 81 | * one included in your C library |
robert_jw | 0:b2805b6888dc | 82 | */ |
robert_jw | 0:b2805b6888dc | 83 | #ifndef MEMCPY |
robert_jw | 0:b2805b6888dc | 84 | #define MEMCPY(dst,src,len) memcpy(dst,src,len) |
robert_jw | 0:b2805b6888dc | 85 | #endif |
robert_jw | 0:b2805b6888dc | 86 | |
robert_jw | 0:b2805b6888dc | 87 | /** |
robert_jw | 0:b2805b6888dc | 88 | * SMEMCPY: override this with care! Some compilers (e.g. gcc) can inline a |
robert_jw | 0:b2805b6888dc | 89 | * call to memcpy() if the length is known at compile time and is small. |
robert_jw | 0:b2805b6888dc | 90 | */ |
robert_jw | 0:b2805b6888dc | 91 | #ifndef SMEMCPY |
robert_jw | 0:b2805b6888dc | 92 | #define SMEMCPY(dst,src,len) memcpy(dst,src,len) |
robert_jw | 0:b2805b6888dc | 93 | #endif |
robert_jw | 0:b2805b6888dc | 94 | |
robert_jw | 0:b2805b6888dc | 95 | /* |
robert_jw | 0:b2805b6888dc | 96 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 97 | ---------- Memory options ---------- |
robert_jw | 0:b2805b6888dc | 98 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 99 | */ |
robert_jw | 0:b2805b6888dc | 100 | /** |
robert_jw | 0:b2805b6888dc | 101 | * MEM_LIBC_MALLOC==1: Use malloc/free/realloc provided by your C-library |
robert_jw | 0:b2805b6888dc | 102 | * instead of the lwip internal allocator. Can save code size if you |
robert_jw | 0:b2805b6888dc | 103 | * already use it. |
robert_jw | 0:b2805b6888dc | 104 | */ |
robert_jw | 0:b2805b6888dc | 105 | #ifndef MEM_LIBC_MALLOC |
robert_jw | 0:b2805b6888dc | 106 | #define MEM_LIBC_MALLOC 0 |
robert_jw | 0:b2805b6888dc | 107 | #endif |
robert_jw | 0:b2805b6888dc | 108 | |
robert_jw | 0:b2805b6888dc | 109 | /** |
robert_jw | 0:b2805b6888dc | 110 | * MEMP_MEM_MALLOC==1: Use mem_malloc/mem_free instead of the lwip pool allocator. |
robert_jw | 0:b2805b6888dc | 111 | * Especially useful with MEM_LIBC_MALLOC but handle with care regarding execution |
robert_jw | 0:b2805b6888dc | 112 | * speed and usage from interrupts! |
robert_jw | 0:b2805b6888dc | 113 | */ |
robert_jw | 0:b2805b6888dc | 114 | #ifndef MEMP_MEM_MALLOC |
robert_jw | 0:b2805b6888dc | 115 | #define MEMP_MEM_MALLOC 0 |
robert_jw | 0:b2805b6888dc | 116 | #endif |
robert_jw | 0:b2805b6888dc | 117 | |
robert_jw | 0:b2805b6888dc | 118 | /** |
robert_jw | 0:b2805b6888dc | 119 | * MEM_ALIGNMENT: should be set to the alignment of the CPU |
robert_jw | 0:b2805b6888dc | 120 | * 4 byte alignment -> #define MEM_ALIGNMENT 4 |
robert_jw | 0:b2805b6888dc | 121 | * 2 byte alignment -> #define MEM_ALIGNMENT 2 |
robert_jw | 0:b2805b6888dc | 122 | */ |
robert_jw | 0:b2805b6888dc | 123 | #ifndef MEM_ALIGNMENT |
robert_jw | 0:b2805b6888dc | 124 | #define MEM_ALIGNMENT 1 |
robert_jw | 0:b2805b6888dc | 125 | #endif |
robert_jw | 0:b2805b6888dc | 126 | |
robert_jw | 0:b2805b6888dc | 127 | /** |
robert_jw | 0:b2805b6888dc | 128 | * MEM_SIZE: the size of the heap memory. If the application will send |
robert_jw | 0:b2805b6888dc | 129 | * a lot of data that needs to be copied, this should be set high. |
robert_jw | 0:b2805b6888dc | 130 | */ |
robert_jw | 0:b2805b6888dc | 131 | #ifndef MEM_SIZE |
robert_jw | 0:b2805b6888dc | 132 | #define MEM_SIZE 1600 |
robert_jw | 0:b2805b6888dc | 133 | #endif |
robert_jw | 0:b2805b6888dc | 134 | |
robert_jw | 0:b2805b6888dc | 135 | /** |
robert_jw | 0:b2805b6888dc | 136 | * MEMP_SEPARATE_POOLS: if defined to 1, each pool is placed in its own array. |
robert_jw | 0:b2805b6888dc | 137 | * This can be used to individually change the location of each pool. |
robert_jw | 0:b2805b6888dc | 138 | * Default is one big array for all pools |
robert_jw | 0:b2805b6888dc | 139 | */ |
robert_jw | 0:b2805b6888dc | 140 | #ifndef MEMP_SEPARATE_POOLS |
robert_jw | 0:b2805b6888dc | 141 | #define MEMP_SEPARATE_POOLS 0 |
robert_jw | 0:b2805b6888dc | 142 | #endif |
robert_jw | 0:b2805b6888dc | 143 | |
robert_jw | 0:b2805b6888dc | 144 | /** |
robert_jw | 0:b2805b6888dc | 145 | * MEMP_OVERFLOW_CHECK: memp overflow protection reserves a configurable |
robert_jw | 0:b2805b6888dc | 146 | * amount of bytes before and after each memp element in every pool and fills |
robert_jw | 0:b2805b6888dc | 147 | * it with a prominent default value. |
robert_jw | 0:b2805b6888dc | 148 | * MEMP_OVERFLOW_CHECK == 0 no checking |
robert_jw | 0:b2805b6888dc | 149 | * MEMP_OVERFLOW_CHECK == 1 checks each element when it is freed |
robert_jw | 0:b2805b6888dc | 150 | * MEMP_OVERFLOW_CHECK >= 2 checks each element in every pool every time |
robert_jw | 0:b2805b6888dc | 151 | * memp_malloc() or memp_free() is called (useful but slow!) |
robert_jw | 0:b2805b6888dc | 152 | */ |
robert_jw | 0:b2805b6888dc | 153 | #ifndef MEMP_OVERFLOW_CHECK |
robert_jw | 0:b2805b6888dc | 154 | #define MEMP_OVERFLOW_CHECK 0 |
robert_jw | 0:b2805b6888dc | 155 | #endif |
robert_jw | 0:b2805b6888dc | 156 | |
robert_jw | 0:b2805b6888dc | 157 | /** |
robert_jw | 0:b2805b6888dc | 158 | * MEMP_SANITY_CHECK==1: run a sanity check after each memp_free() to make |
robert_jw | 0:b2805b6888dc | 159 | * sure that there are no cycles in the linked lists. |
robert_jw | 0:b2805b6888dc | 160 | */ |
robert_jw | 0:b2805b6888dc | 161 | #ifndef MEMP_SANITY_CHECK |
robert_jw | 0:b2805b6888dc | 162 | #define MEMP_SANITY_CHECK 0 |
robert_jw | 0:b2805b6888dc | 163 | #endif |
robert_jw | 0:b2805b6888dc | 164 | |
robert_jw | 0:b2805b6888dc | 165 | /** |
robert_jw | 0:b2805b6888dc | 166 | * MEM_USE_POOLS==1: Use an alternative to malloc() by allocating from a set |
robert_jw | 0:b2805b6888dc | 167 | * of memory pools of various sizes. When mem_malloc is called, an element of |
robert_jw | 0:b2805b6888dc | 168 | * the smallest pool that can provide the length needed is returned. |
robert_jw | 0:b2805b6888dc | 169 | * To use this, MEMP_USE_CUSTOM_POOLS also has to be enabled. |
robert_jw | 0:b2805b6888dc | 170 | */ |
robert_jw | 0:b2805b6888dc | 171 | #ifndef MEM_USE_POOLS |
robert_jw | 0:b2805b6888dc | 172 | #define MEM_USE_POOLS 0 |
robert_jw | 0:b2805b6888dc | 173 | #endif |
robert_jw | 0:b2805b6888dc | 174 | |
robert_jw | 0:b2805b6888dc | 175 | /** |
robert_jw | 0:b2805b6888dc | 176 | * MEM_USE_POOLS_TRY_BIGGER_POOL==1: if one malloc-pool is empty, try the next |
robert_jw | 0:b2805b6888dc | 177 | * bigger pool - WARNING: THIS MIGHT WASTE MEMORY but it can make a system more |
robert_jw | 0:b2805b6888dc | 178 | * reliable. */ |
robert_jw | 0:b2805b6888dc | 179 | #ifndef MEM_USE_POOLS_TRY_BIGGER_POOL |
robert_jw | 0:b2805b6888dc | 180 | #define MEM_USE_POOLS_TRY_BIGGER_POOL 0 |
robert_jw | 0:b2805b6888dc | 181 | #endif |
robert_jw | 0:b2805b6888dc | 182 | |
robert_jw | 0:b2805b6888dc | 183 | /** |
robert_jw | 0:b2805b6888dc | 184 | * MEMP_USE_CUSTOM_POOLS==1: whether to include a user file lwippools.h |
robert_jw | 0:b2805b6888dc | 185 | * that defines additional pools beyond the "standard" ones required |
robert_jw | 0:b2805b6888dc | 186 | * by lwIP. If you set this to 1, you must have lwippools.h in your |
robert_jw | 0:b2805b6888dc | 187 | * inlude path somewhere. |
robert_jw | 0:b2805b6888dc | 188 | */ |
robert_jw | 0:b2805b6888dc | 189 | #ifndef MEMP_USE_CUSTOM_POOLS |
robert_jw | 0:b2805b6888dc | 190 | #define MEMP_USE_CUSTOM_POOLS 0 |
robert_jw | 0:b2805b6888dc | 191 | #endif |
robert_jw | 0:b2805b6888dc | 192 | |
robert_jw | 0:b2805b6888dc | 193 | /** |
robert_jw | 0:b2805b6888dc | 194 | * Set this to 1 if you want to free PBUF_RAM pbufs (or call mem_free()) from |
robert_jw | 0:b2805b6888dc | 195 | * interrupt context (or another context that doesn't allow waiting for a |
robert_jw | 0:b2805b6888dc | 196 | * semaphore). |
robert_jw | 0:b2805b6888dc | 197 | * If set to 1, mem_malloc will be protected by a semaphore and SYS_ARCH_PROTECT, |
robert_jw | 0:b2805b6888dc | 198 | * while mem_free will only use SYS_ARCH_PROTECT. mem_malloc SYS_ARCH_UNPROTECTs |
robert_jw | 0:b2805b6888dc | 199 | * with each loop so that mem_free can run. |
robert_jw | 0:b2805b6888dc | 200 | * |
robert_jw | 0:b2805b6888dc | 201 | * ATTENTION: As you can see from the above description, this leads to dis-/ |
robert_jw | 0:b2805b6888dc | 202 | * enabling interrupts often, which can be slow! Also, on low memory, mem_malloc |
robert_jw | 0:b2805b6888dc | 203 | * can need longer. |
robert_jw | 0:b2805b6888dc | 204 | * |
robert_jw | 0:b2805b6888dc | 205 | * If you don't want that, at least for NO_SYS=0, you can still use the following |
robert_jw | 0:b2805b6888dc | 206 | * functions to enqueue a deallocation call which then runs in the tcpip_thread |
robert_jw | 0:b2805b6888dc | 207 | * context: |
robert_jw | 0:b2805b6888dc | 208 | * - pbuf_free_callback(p); |
robert_jw | 0:b2805b6888dc | 209 | * - mem_free_callback(m); |
robert_jw | 0:b2805b6888dc | 210 | */ |
robert_jw | 0:b2805b6888dc | 211 | #ifndef LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT |
robert_jw | 0:b2805b6888dc | 212 | #define LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT 0 |
robert_jw | 0:b2805b6888dc | 213 | #endif |
robert_jw | 0:b2805b6888dc | 214 | |
robert_jw | 0:b2805b6888dc | 215 | /* |
robert_jw | 0:b2805b6888dc | 216 | ------------------------------------------------ |
robert_jw | 0:b2805b6888dc | 217 | ---------- Internal Memory Pool Sizes ---------- |
robert_jw | 0:b2805b6888dc | 218 | ------------------------------------------------ |
robert_jw | 0:b2805b6888dc | 219 | */ |
robert_jw | 0:b2805b6888dc | 220 | /** |
robert_jw | 0:b2805b6888dc | 221 | * MEMP_NUM_PBUF: the number of memp struct pbufs (used for PBUF_ROM and PBUF_REF). |
robert_jw | 0:b2805b6888dc | 222 | * If the application sends a lot of data out of ROM (or other static memory), |
robert_jw | 0:b2805b6888dc | 223 | * this should be set high. |
robert_jw | 0:b2805b6888dc | 224 | */ |
robert_jw | 0:b2805b6888dc | 225 | #ifndef MEMP_NUM_PBUF |
robert_jw | 0:b2805b6888dc | 226 | #define MEMP_NUM_PBUF 16 |
robert_jw | 0:b2805b6888dc | 227 | #endif |
robert_jw | 0:b2805b6888dc | 228 | |
robert_jw | 0:b2805b6888dc | 229 | /** |
robert_jw | 0:b2805b6888dc | 230 | * MEMP_NUM_RAW_PCB: Number of raw connection PCBs |
robert_jw | 0:b2805b6888dc | 231 | * (requires the LWIP_RAW option) |
robert_jw | 0:b2805b6888dc | 232 | */ |
robert_jw | 0:b2805b6888dc | 233 | #ifndef MEMP_NUM_RAW_PCB |
robert_jw | 0:b2805b6888dc | 234 | #define MEMP_NUM_RAW_PCB 4 |
robert_jw | 0:b2805b6888dc | 235 | #endif |
robert_jw | 0:b2805b6888dc | 236 | |
robert_jw | 0:b2805b6888dc | 237 | /** |
robert_jw | 0:b2805b6888dc | 238 | * MEMP_NUM_UDP_PCB: the number of UDP protocol control blocks. One |
robert_jw | 0:b2805b6888dc | 239 | * per active UDP "connection". |
robert_jw | 0:b2805b6888dc | 240 | * (requires the LWIP_UDP option) |
robert_jw | 0:b2805b6888dc | 241 | */ |
robert_jw | 0:b2805b6888dc | 242 | #ifndef MEMP_NUM_UDP_PCB |
robert_jw | 0:b2805b6888dc | 243 | #define MEMP_NUM_UDP_PCB 4 |
robert_jw | 0:b2805b6888dc | 244 | #endif |
robert_jw | 0:b2805b6888dc | 245 | |
robert_jw | 0:b2805b6888dc | 246 | /** |
robert_jw | 0:b2805b6888dc | 247 | * MEMP_NUM_TCP_PCB: the number of simulatenously active TCP connections. |
robert_jw | 0:b2805b6888dc | 248 | * (requires the LWIP_TCP option) |
robert_jw | 0:b2805b6888dc | 249 | */ |
robert_jw | 0:b2805b6888dc | 250 | #ifndef MEMP_NUM_TCP_PCB |
robert_jw | 0:b2805b6888dc | 251 | #define MEMP_NUM_TCP_PCB 5 |
robert_jw | 0:b2805b6888dc | 252 | #endif |
robert_jw | 0:b2805b6888dc | 253 | |
robert_jw | 0:b2805b6888dc | 254 | /** |
robert_jw | 0:b2805b6888dc | 255 | * MEMP_NUM_TCP_PCB_LISTEN: the number of listening TCP connections. |
robert_jw | 0:b2805b6888dc | 256 | * (requires the LWIP_TCP option) |
robert_jw | 0:b2805b6888dc | 257 | */ |
robert_jw | 0:b2805b6888dc | 258 | #ifndef MEMP_NUM_TCP_PCB_LISTEN |
robert_jw | 0:b2805b6888dc | 259 | #define MEMP_NUM_TCP_PCB_LISTEN 8 |
robert_jw | 0:b2805b6888dc | 260 | #endif |
robert_jw | 0:b2805b6888dc | 261 | |
robert_jw | 0:b2805b6888dc | 262 | /** |
robert_jw | 0:b2805b6888dc | 263 | * MEMP_NUM_TCP_SEG: the number of simultaneously queued TCP segments. |
robert_jw | 0:b2805b6888dc | 264 | * (requires the LWIP_TCP option) |
robert_jw | 0:b2805b6888dc | 265 | */ |
robert_jw | 0:b2805b6888dc | 266 | #ifndef MEMP_NUM_TCP_SEG |
robert_jw | 0:b2805b6888dc | 267 | #define MEMP_NUM_TCP_SEG 16 |
robert_jw | 0:b2805b6888dc | 268 | #endif |
robert_jw | 0:b2805b6888dc | 269 | |
robert_jw | 0:b2805b6888dc | 270 | /** |
robert_jw | 0:b2805b6888dc | 271 | * MEMP_NUM_REASSDATA: the number of IP packets simultaneously queued for |
robert_jw | 0:b2805b6888dc | 272 | * reassembly (whole packets, not fragments!) |
robert_jw | 0:b2805b6888dc | 273 | */ |
robert_jw | 0:b2805b6888dc | 274 | #ifndef MEMP_NUM_REASSDATA |
robert_jw | 0:b2805b6888dc | 275 | #define MEMP_NUM_REASSDATA 5 |
robert_jw | 0:b2805b6888dc | 276 | #endif |
robert_jw | 0:b2805b6888dc | 277 | |
robert_jw | 0:b2805b6888dc | 278 | /** |
robert_jw | 0:b2805b6888dc | 279 | * MEMP_NUM_FRAG_PBUF: the number of IP fragments simultaneously sent |
robert_jw | 0:b2805b6888dc | 280 | * (fragments, not whole packets!). |
robert_jw | 0:b2805b6888dc | 281 | * This is only used with IP_FRAG_USES_STATIC_BUF==0 and |
robert_jw | 0:b2805b6888dc | 282 | * LWIP_NETIF_TX_SINGLE_PBUF==0 and only has to be > 1 with DMA-enabled MACs |
robert_jw | 0:b2805b6888dc | 283 | * where the packet is not yet sent when netif->output returns. |
robert_jw | 0:b2805b6888dc | 284 | */ |
robert_jw | 0:b2805b6888dc | 285 | #ifndef MEMP_NUM_FRAG_PBUF |
robert_jw | 0:b2805b6888dc | 286 | #define MEMP_NUM_FRAG_PBUF 15 |
robert_jw | 0:b2805b6888dc | 287 | #endif |
robert_jw | 0:b2805b6888dc | 288 | |
robert_jw | 0:b2805b6888dc | 289 | /** |
robert_jw | 0:b2805b6888dc | 290 | * MEMP_NUM_ARP_QUEUE: the number of simulateously queued outgoing |
robert_jw | 0:b2805b6888dc | 291 | * packets (pbufs) that are waiting for an ARP request (to resolve |
robert_jw | 0:b2805b6888dc | 292 | * their destination address) to finish. |
robert_jw | 0:b2805b6888dc | 293 | * (requires the ARP_QUEUEING option) |
robert_jw | 0:b2805b6888dc | 294 | */ |
robert_jw | 0:b2805b6888dc | 295 | #ifndef MEMP_NUM_ARP_QUEUE |
robert_jw | 0:b2805b6888dc | 296 | #define MEMP_NUM_ARP_QUEUE 30 |
robert_jw | 0:b2805b6888dc | 297 | #endif |
robert_jw | 0:b2805b6888dc | 298 | |
robert_jw | 0:b2805b6888dc | 299 | /** |
robert_jw | 0:b2805b6888dc | 300 | * MEMP_NUM_IGMP_GROUP: The number of multicast groups whose network interfaces |
robert_jw | 0:b2805b6888dc | 301 | * can be members et the same time (one per netif - allsystems group -, plus one |
robert_jw | 0:b2805b6888dc | 302 | * per netif membership). |
robert_jw | 0:b2805b6888dc | 303 | * (requires the LWIP_IGMP option) |
robert_jw | 0:b2805b6888dc | 304 | */ |
robert_jw | 0:b2805b6888dc | 305 | #ifndef MEMP_NUM_IGMP_GROUP |
robert_jw | 0:b2805b6888dc | 306 | #define MEMP_NUM_IGMP_GROUP 8 |
robert_jw | 0:b2805b6888dc | 307 | #endif |
robert_jw | 0:b2805b6888dc | 308 | |
robert_jw | 0:b2805b6888dc | 309 | /** |
robert_jw | 0:b2805b6888dc | 310 | * MEMP_NUM_SYS_TIMEOUT: the number of simulateously active timeouts. |
robert_jw | 0:b2805b6888dc | 311 | * (requires NO_SYS==0) |
robert_jw | 0:b2805b6888dc | 312 | */ |
robert_jw | 0:b2805b6888dc | 313 | #ifndef MEMP_NUM_SYS_TIMEOUT |
robert_jw | 0:b2805b6888dc | 314 | #define MEMP_NUM_SYS_TIMEOUT 3 |
robert_jw | 0:b2805b6888dc | 315 | #endif |
robert_jw | 0:b2805b6888dc | 316 | |
robert_jw | 0:b2805b6888dc | 317 | /** |
robert_jw | 0:b2805b6888dc | 318 | * MEMP_NUM_NETBUF: the number of struct netbufs. |
robert_jw | 0:b2805b6888dc | 319 | * (only needed if you use the sequential API, like api_lib.c) |
robert_jw | 0:b2805b6888dc | 320 | */ |
robert_jw | 0:b2805b6888dc | 321 | #ifndef MEMP_NUM_NETBUF |
robert_jw | 0:b2805b6888dc | 322 | #define MEMP_NUM_NETBUF 2 |
robert_jw | 0:b2805b6888dc | 323 | #endif |
robert_jw | 0:b2805b6888dc | 324 | |
robert_jw | 0:b2805b6888dc | 325 | /** |
robert_jw | 0:b2805b6888dc | 326 | * MEMP_NUM_NETCONN: the number of struct netconns. |
robert_jw | 0:b2805b6888dc | 327 | * (only needed if you use the sequential API, like api_lib.c) |
robert_jw | 0:b2805b6888dc | 328 | */ |
robert_jw | 0:b2805b6888dc | 329 | #ifndef MEMP_NUM_NETCONN |
robert_jw | 0:b2805b6888dc | 330 | #define MEMP_NUM_NETCONN 4 |
robert_jw | 0:b2805b6888dc | 331 | #endif |
robert_jw | 0:b2805b6888dc | 332 | |
robert_jw | 0:b2805b6888dc | 333 | /** |
robert_jw | 0:b2805b6888dc | 334 | * MEMP_NUM_TCPIP_MSG_API: the number of struct tcpip_msg, which are used |
robert_jw | 0:b2805b6888dc | 335 | * for callback/timeout API communication. |
robert_jw | 0:b2805b6888dc | 336 | * (only needed if you use tcpip.c) |
robert_jw | 0:b2805b6888dc | 337 | */ |
robert_jw | 0:b2805b6888dc | 338 | #ifndef MEMP_NUM_TCPIP_MSG_API |
robert_jw | 0:b2805b6888dc | 339 | #define MEMP_NUM_TCPIP_MSG_API 8 |
robert_jw | 0:b2805b6888dc | 340 | #endif |
robert_jw | 0:b2805b6888dc | 341 | |
robert_jw | 0:b2805b6888dc | 342 | /** |
robert_jw | 0:b2805b6888dc | 343 | * MEMP_NUM_TCPIP_MSG_INPKT: the number of struct tcpip_msg, which are used |
robert_jw | 0:b2805b6888dc | 344 | * for incoming packets. |
robert_jw | 0:b2805b6888dc | 345 | * (only needed if you use tcpip.c) |
robert_jw | 0:b2805b6888dc | 346 | */ |
robert_jw | 0:b2805b6888dc | 347 | #ifndef MEMP_NUM_TCPIP_MSG_INPKT |
robert_jw | 0:b2805b6888dc | 348 | #define MEMP_NUM_TCPIP_MSG_INPKT 8 |
robert_jw | 0:b2805b6888dc | 349 | #endif |
robert_jw | 0:b2805b6888dc | 350 | |
robert_jw | 0:b2805b6888dc | 351 | /** |
robert_jw | 0:b2805b6888dc | 352 | * MEMP_NUM_SNMP_NODE: the number of leafs in the SNMP tree. |
robert_jw | 0:b2805b6888dc | 353 | */ |
robert_jw | 0:b2805b6888dc | 354 | #ifndef MEMP_NUM_SNMP_NODE |
robert_jw | 0:b2805b6888dc | 355 | #define MEMP_NUM_SNMP_NODE 50 |
robert_jw | 0:b2805b6888dc | 356 | #endif |
robert_jw | 0:b2805b6888dc | 357 | |
robert_jw | 0:b2805b6888dc | 358 | /** |
robert_jw | 0:b2805b6888dc | 359 | * MEMP_NUM_SNMP_ROOTNODE: the number of branches in the SNMP tree. |
robert_jw | 0:b2805b6888dc | 360 | * Every branch has one leaf (MEMP_NUM_SNMP_NODE) at least! |
robert_jw | 0:b2805b6888dc | 361 | */ |
robert_jw | 0:b2805b6888dc | 362 | #ifndef MEMP_NUM_SNMP_ROOTNODE |
robert_jw | 0:b2805b6888dc | 363 | #define MEMP_NUM_SNMP_ROOTNODE 30 |
robert_jw | 0:b2805b6888dc | 364 | #endif |
robert_jw | 0:b2805b6888dc | 365 | |
robert_jw | 0:b2805b6888dc | 366 | /** |
robert_jw | 0:b2805b6888dc | 367 | * MEMP_NUM_SNMP_VARBIND: the number of concurrent requests (does not have to |
robert_jw | 0:b2805b6888dc | 368 | * be changed normally) - 2 of these are used per request (1 for input, |
robert_jw | 0:b2805b6888dc | 369 | * 1 for output) |
robert_jw | 0:b2805b6888dc | 370 | */ |
robert_jw | 0:b2805b6888dc | 371 | #ifndef MEMP_NUM_SNMP_VARBIND |
robert_jw | 0:b2805b6888dc | 372 | #define MEMP_NUM_SNMP_VARBIND 2 |
robert_jw | 0:b2805b6888dc | 373 | #endif |
robert_jw | 0:b2805b6888dc | 374 | |
robert_jw | 0:b2805b6888dc | 375 | /** |
robert_jw | 0:b2805b6888dc | 376 | * MEMP_NUM_SNMP_VALUE: the number of OID or values concurrently used |
robert_jw | 0:b2805b6888dc | 377 | * (does not have to be changed normally) - 3 of these are used per request |
robert_jw | 0:b2805b6888dc | 378 | * (1 for the value read and 2 for OIDs - input and output) |
robert_jw | 0:b2805b6888dc | 379 | */ |
robert_jw | 0:b2805b6888dc | 380 | #ifndef MEMP_NUM_SNMP_VALUE |
robert_jw | 0:b2805b6888dc | 381 | #define MEMP_NUM_SNMP_VALUE 3 |
robert_jw | 0:b2805b6888dc | 382 | #endif |
robert_jw | 0:b2805b6888dc | 383 | |
robert_jw | 0:b2805b6888dc | 384 | /** |
robert_jw | 0:b2805b6888dc | 385 | * MEMP_NUM_NETDB: the number of concurrently running lwip_addrinfo() calls |
robert_jw | 0:b2805b6888dc | 386 | * (before freeing the corresponding memory using lwip_freeaddrinfo()). |
robert_jw | 0:b2805b6888dc | 387 | */ |
robert_jw | 0:b2805b6888dc | 388 | #ifndef MEMP_NUM_NETDB |
robert_jw | 0:b2805b6888dc | 389 | #define MEMP_NUM_NETDB 1 |
robert_jw | 0:b2805b6888dc | 390 | #endif |
robert_jw | 0:b2805b6888dc | 391 | |
robert_jw | 0:b2805b6888dc | 392 | /** |
robert_jw | 0:b2805b6888dc | 393 | * MEMP_NUM_LOCALHOSTLIST: the number of host entries in the local host list |
robert_jw | 0:b2805b6888dc | 394 | * if DNS_LOCAL_HOSTLIST_IS_DYNAMIC==1. |
robert_jw | 0:b2805b6888dc | 395 | */ |
robert_jw | 0:b2805b6888dc | 396 | #ifndef MEMP_NUM_LOCALHOSTLIST |
robert_jw | 0:b2805b6888dc | 397 | #define MEMP_NUM_LOCALHOSTLIST 1 |
robert_jw | 0:b2805b6888dc | 398 | #endif |
robert_jw | 0:b2805b6888dc | 399 | |
robert_jw | 0:b2805b6888dc | 400 | /** |
robert_jw | 0:b2805b6888dc | 401 | * MEMP_NUM_PPPOE_INTERFACES: the number of concurrently active PPPoE |
robert_jw | 0:b2805b6888dc | 402 | * interfaces (only used with PPPOE_SUPPORT==1) |
robert_jw | 0:b2805b6888dc | 403 | */ |
robert_jw | 0:b2805b6888dc | 404 | #ifndef MEMP_NUM_PPPOE_INTERFACES |
robert_jw | 0:b2805b6888dc | 405 | #define MEMP_NUM_PPPOE_INTERFACES 1 |
robert_jw | 0:b2805b6888dc | 406 | #endif |
robert_jw | 0:b2805b6888dc | 407 | |
robert_jw | 0:b2805b6888dc | 408 | /** |
robert_jw | 0:b2805b6888dc | 409 | * PBUF_POOL_SIZE: the number of buffers in the pbuf pool. |
robert_jw | 0:b2805b6888dc | 410 | */ |
robert_jw | 0:b2805b6888dc | 411 | #ifndef PBUF_POOL_SIZE |
robert_jw | 0:b2805b6888dc | 412 | #define PBUF_POOL_SIZE 16 |
robert_jw | 0:b2805b6888dc | 413 | #endif |
robert_jw | 0:b2805b6888dc | 414 | |
robert_jw | 0:b2805b6888dc | 415 | /* |
robert_jw | 0:b2805b6888dc | 416 | --------------------------------- |
robert_jw | 0:b2805b6888dc | 417 | ---------- ARP options ---------- |
robert_jw | 0:b2805b6888dc | 418 | --------------------------------- |
robert_jw | 0:b2805b6888dc | 419 | */ |
robert_jw | 0:b2805b6888dc | 420 | /** |
robert_jw | 0:b2805b6888dc | 421 | * LWIP_ARP==1: Enable ARP functionality. |
robert_jw | 0:b2805b6888dc | 422 | */ |
robert_jw | 0:b2805b6888dc | 423 | #ifndef LWIP_ARP |
robert_jw | 0:b2805b6888dc | 424 | #define LWIP_ARP 1 |
robert_jw | 0:b2805b6888dc | 425 | #endif |
robert_jw | 0:b2805b6888dc | 426 | |
robert_jw | 0:b2805b6888dc | 427 | /** |
robert_jw | 0:b2805b6888dc | 428 | * ARP_TABLE_SIZE: Number of active MAC-IP address pairs cached. |
robert_jw | 0:b2805b6888dc | 429 | */ |
robert_jw | 0:b2805b6888dc | 430 | #ifndef ARP_TABLE_SIZE |
robert_jw | 0:b2805b6888dc | 431 | #define ARP_TABLE_SIZE 10 |
robert_jw | 0:b2805b6888dc | 432 | #endif |
robert_jw | 0:b2805b6888dc | 433 | |
robert_jw | 0:b2805b6888dc | 434 | /** |
robert_jw | 0:b2805b6888dc | 435 | * ARP_QUEUEING==1: Multiple outgoing packets are queued during hardware address |
robert_jw | 0:b2805b6888dc | 436 | * resolution. By default, only the most recent packet is queued per IP address. |
robert_jw | 0:b2805b6888dc | 437 | * This is sufficient for most protocols and mainly reduces TCP connection |
robert_jw | 0:b2805b6888dc | 438 | * startup time. Set this to 1 if you know your application sends more than one |
robert_jw | 0:b2805b6888dc | 439 | * packet in a row to an IP address that is not in the ARP cache. |
robert_jw | 0:b2805b6888dc | 440 | */ |
robert_jw | 0:b2805b6888dc | 441 | #ifndef ARP_QUEUEING |
robert_jw | 0:b2805b6888dc | 442 | #define ARP_QUEUEING 0 |
robert_jw | 0:b2805b6888dc | 443 | #endif |
robert_jw | 0:b2805b6888dc | 444 | |
robert_jw | 0:b2805b6888dc | 445 | /** |
robert_jw | 0:b2805b6888dc | 446 | * ETHARP_TRUST_IP_MAC==1: Incoming IP packets cause the ARP table to be |
robert_jw | 0:b2805b6888dc | 447 | * updated with the source MAC and IP addresses supplied in the packet. |
robert_jw | 0:b2805b6888dc | 448 | * You may want to disable this if you do not trust LAN peers to have the |
robert_jw | 0:b2805b6888dc | 449 | * correct addresses, or as a limited approach to attempt to handle |
robert_jw | 0:b2805b6888dc | 450 | * spoofing. If disabled, lwIP will need to make a new ARP request if |
robert_jw | 0:b2805b6888dc | 451 | * the peer is not already in the ARP table, adding a little latency. |
robert_jw | 0:b2805b6888dc | 452 | * The peer *is* in the ARP table if it requested our address before. |
robert_jw | 0:b2805b6888dc | 453 | * Also notice that this slows down input processing of every IP packet! |
robert_jw | 0:b2805b6888dc | 454 | */ |
robert_jw | 0:b2805b6888dc | 455 | #ifndef ETHARP_TRUST_IP_MAC |
robert_jw | 0:b2805b6888dc | 456 | #define ETHARP_TRUST_IP_MAC 0 |
robert_jw | 0:b2805b6888dc | 457 | #endif |
robert_jw | 0:b2805b6888dc | 458 | |
robert_jw | 0:b2805b6888dc | 459 | /** |
robert_jw | 0:b2805b6888dc | 460 | * ETHARP_SUPPORT_VLAN==1: support receiving ethernet packets with VLAN header. |
robert_jw | 0:b2805b6888dc | 461 | * Additionally, you can define ETHARP_VLAN_CHECK to an u16_t VLAN ID to check. |
robert_jw | 0:b2805b6888dc | 462 | * If ETHARP_VLAN_CHECK is defined, only VLAN-traffic for this VLAN is accepted. |
robert_jw | 0:b2805b6888dc | 463 | * If ETHARP_VLAN_CHECK is not defined, all traffic is accepted. |
robert_jw | 0:b2805b6888dc | 464 | */ |
robert_jw | 0:b2805b6888dc | 465 | #ifndef ETHARP_SUPPORT_VLAN |
robert_jw | 0:b2805b6888dc | 466 | #define ETHARP_SUPPORT_VLAN 0 |
robert_jw | 0:b2805b6888dc | 467 | #endif |
robert_jw | 0:b2805b6888dc | 468 | |
robert_jw | 0:b2805b6888dc | 469 | /** LWIP_ETHERNET==1: enable ethernet support for PPPoE even though ARP |
robert_jw | 0:b2805b6888dc | 470 | * might be disabled |
robert_jw | 0:b2805b6888dc | 471 | */ |
robert_jw | 0:b2805b6888dc | 472 | #ifndef LWIP_ETHERNET |
robert_jw | 0:b2805b6888dc | 473 | #define LWIP_ETHERNET (LWIP_ARP || PPPOE_SUPPORT) |
robert_jw | 0:b2805b6888dc | 474 | #endif |
robert_jw | 0:b2805b6888dc | 475 | |
robert_jw | 0:b2805b6888dc | 476 | /** ETH_PAD_SIZE: number of bytes added before the ethernet header to ensure |
robert_jw | 0:b2805b6888dc | 477 | * alignment of payload after that header. Since the header is 14 bytes long, |
robert_jw | 0:b2805b6888dc | 478 | * without this padding e.g. addresses in the IP header will not be aligned |
robert_jw | 0:b2805b6888dc | 479 | * on a 32-bit boundary, so setting this to 2 can speed up 32-bit-platforms. |
robert_jw | 0:b2805b6888dc | 480 | */ |
robert_jw | 0:b2805b6888dc | 481 | #ifndef ETH_PAD_SIZE |
robert_jw | 0:b2805b6888dc | 482 | #define ETH_PAD_SIZE 0 |
robert_jw | 0:b2805b6888dc | 483 | #endif |
robert_jw | 0:b2805b6888dc | 484 | |
robert_jw | 0:b2805b6888dc | 485 | /** ETHARP_SUPPORT_STATIC_ENTRIES==1: enable code to support static ARP table |
robert_jw | 0:b2805b6888dc | 486 | * entries (using etharp_add_static_entry/etharp_remove_static_entry). |
robert_jw | 0:b2805b6888dc | 487 | */ |
robert_jw | 0:b2805b6888dc | 488 | #ifndef ETHARP_SUPPORT_STATIC_ENTRIES |
robert_jw | 0:b2805b6888dc | 489 | #define ETHARP_SUPPORT_STATIC_ENTRIES 0 |
robert_jw | 0:b2805b6888dc | 490 | #endif |
robert_jw | 0:b2805b6888dc | 491 | |
robert_jw | 0:b2805b6888dc | 492 | |
robert_jw | 0:b2805b6888dc | 493 | /* |
robert_jw | 0:b2805b6888dc | 494 | -------------------------------- |
robert_jw | 0:b2805b6888dc | 495 | ---------- IP options ---------- |
robert_jw | 0:b2805b6888dc | 496 | -------------------------------- |
robert_jw | 0:b2805b6888dc | 497 | */ |
robert_jw | 0:b2805b6888dc | 498 | /** |
robert_jw | 0:b2805b6888dc | 499 | * IP_FORWARD==1: Enables the ability to forward IP packets across network |
robert_jw | 0:b2805b6888dc | 500 | * interfaces. If you are going to run lwIP on a device with only one network |
robert_jw | 0:b2805b6888dc | 501 | * interface, define this to 0. |
robert_jw | 0:b2805b6888dc | 502 | */ |
robert_jw | 0:b2805b6888dc | 503 | #ifndef IP_FORWARD |
robert_jw | 0:b2805b6888dc | 504 | #define IP_FORWARD 0 |
robert_jw | 0:b2805b6888dc | 505 | #endif |
robert_jw | 0:b2805b6888dc | 506 | |
robert_jw | 0:b2805b6888dc | 507 | /** |
robert_jw | 0:b2805b6888dc | 508 | * IP_OPTIONS_ALLOWED: Defines the behavior for IP options. |
robert_jw | 0:b2805b6888dc | 509 | * IP_OPTIONS_ALLOWED==0: All packets with IP options are dropped. |
robert_jw | 0:b2805b6888dc | 510 | * IP_OPTIONS_ALLOWED==1: IP options are allowed (but not parsed). |
robert_jw | 0:b2805b6888dc | 511 | */ |
robert_jw | 0:b2805b6888dc | 512 | #ifndef IP_OPTIONS_ALLOWED |
robert_jw | 0:b2805b6888dc | 513 | #define IP_OPTIONS_ALLOWED 1 |
robert_jw | 0:b2805b6888dc | 514 | #endif |
robert_jw | 0:b2805b6888dc | 515 | |
robert_jw | 0:b2805b6888dc | 516 | /** |
robert_jw | 0:b2805b6888dc | 517 | * IP_REASSEMBLY==1: Reassemble incoming fragmented IP packets. Note that |
robert_jw | 0:b2805b6888dc | 518 | * this option does not affect outgoing packet sizes, which can be controlled |
robert_jw | 0:b2805b6888dc | 519 | * via IP_FRAG. |
robert_jw | 0:b2805b6888dc | 520 | */ |
robert_jw | 0:b2805b6888dc | 521 | #ifndef IP_REASSEMBLY |
robert_jw | 0:b2805b6888dc | 522 | #define IP_REASSEMBLY 1 |
robert_jw | 0:b2805b6888dc | 523 | #endif |
robert_jw | 0:b2805b6888dc | 524 | |
robert_jw | 0:b2805b6888dc | 525 | /** |
robert_jw | 0:b2805b6888dc | 526 | * IP_FRAG==1: Fragment outgoing IP packets if their size exceeds MTU. Note |
robert_jw | 0:b2805b6888dc | 527 | * that this option does not affect incoming packet sizes, which can be |
robert_jw | 0:b2805b6888dc | 528 | * controlled via IP_REASSEMBLY. |
robert_jw | 0:b2805b6888dc | 529 | */ |
robert_jw | 0:b2805b6888dc | 530 | #ifndef IP_FRAG |
robert_jw | 0:b2805b6888dc | 531 | #define IP_FRAG 1 |
robert_jw | 0:b2805b6888dc | 532 | #endif |
robert_jw | 0:b2805b6888dc | 533 | |
robert_jw | 0:b2805b6888dc | 534 | /** |
robert_jw | 0:b2805b6888dc | 535 | * IP_REASS_MAXAGE: Maximum time (in multiples of IP_TMR_INTERVAL - so seconds, normally) |
robert_jw | 0:b2805b6888dc | 536 | * a fragmented IP packet waits for all fragments to arrive. If not all fragments arrived |
robert_jw | 0:b2805b6888dc | 537 | * in this time, the whole packet is discarded. |
robert_jw | 0:b2805b6888dc | 538 | */ |
robert_jw | 0:b2805b6888dc | 539 | #ifndef IP_REASS_MAXAGE |
robert_jw | 0:b2805b6888dc | 540 | #define IP_REASS_MAXAGE 3 |
robert_jw | 0:b2805b6888dc | 541 | #endif |
robert_jw | 0:b2805b6888dc | 542 | |
robert_jw | 0:b2805b6888dc | 543 | /** |
robert_jw | 0:b2805b6888dc | 544 | * IP_REASS_MAX_PBUFS: Total maximum amount of pbufs waiting to be reassembled. |
robert_jw | 0:b2805b6888dc | 545 | * Since the received pbufs are enqueued, be sure to configure |
robert_jw | 0:b2805b6888dc | 546 | * PBUF_POOL_SIZE > IP_REASS_MAX_PBUFS so that the stack is still able to receive |
robert_jw | 0:b2805b6888dc | 547 | * packets even if the maximum amount of fragments is enqueued for reassembly! |
robert_jw | 0:b2805b6888dc | 548 | */ |
robert_jw | 0:b2805b6888dc | 549 | #ifndef IP_REASS_MAX_PBUFS |
robert_jw | 0:b2805b6888dc | 550 | #define IP_REASS_MAX_PBUFS 10 |
robert_jw | 0:b2805b6888dc | 551 | #endif |
robert_jw | 0:b2805b6888dc | 552 | |
robert_jw | 0:b2805b6888dc | 553 | /** |
robert_jw | 0:b2805b6888dc | 554 | * IP_FRAG_USES_STATIC_BUF==1: Use a static MTU-sized buffer for IP |
robert_jw | 0:b2805b6888dc | 555 | * fragmentation. Otherwise pbufs are allocated and reference the original |
robert_jw | 0:b2805b6888dc | 556 | * packet data to be fragmented (or with LWIP_NETIF_TX_SINGLE_PBUF==1, |
robert_jw | 0:b2805b6888dc | 557 | * new PBUF_RAM pbufs are used for fragments). |
robert_jw | 0:b2805b6888dc | 558 | * ATTENTION: IP_FRAG_USES_STATIC_BUF==1 may not be used for DMA-enabled MACs! |
robert_jw | 0:b2805b6888dc | 559 | */ |
robert_jw | 0:b2805b6888dc | 560 | #ifndef IP_FRAG_USES_STATIC_BUF |
robert_jw | 0:b2805b6888dc | 561 | #define IP_FRAG_USES_STATIC_BUF 0 |
robert_jw | 0:b2805b6888dc | 562 | #endif |
robert_jw | 0:b2805b6888dc | 563 | |
robert_jw | 0:b2805b6888dc | 564 | /** |
robert_jw | 0:b2805b6888dc | 565 | * IP_FRAG_MAX_MTU: Assumed max MTU on any interface for IP frag buffer |
robert_jw | 0:b2805b6888dc | 566 | * (requires IP_FRAG_USES_STATIC_BUF==1) |
robert_jw | 0:b2805b6888dc | 567 | */ |
robert_jw | 0:b2805b6888dc | 568 | #if IP_FRAG_USES_STATIC_BUF && !defined(IP_FRAG_MAX_MTU) |
robert_jw | 0:b2805b6888dc | 569 | #define IP_FRAG_MAX_MTU 1500 |
robert_jw | 0:b2805b6888dc | 570 | #endif |
robert_jw | 0:b2805b6888dc | 571 | |
robert_jw | 0:b2805b6888dc | 572 | /** |
robert_jw | 0:b2805b6888dc | 573 | * IP_DEFAULT_TTL: Default value for Time-To-Live used by transport layers. |
robert_jw | 0:b2805b6888dc | 574 | */ |
robert_jw | 0:b2805b6888dc | 575 | #ifndef IP_DEFAULT_TTL |
robert_jw | 0:b2805b6888dc | 576 | #define IP_DEFAULT_TTL 255 |
robert_jw | 0:b2805b6888dc | 577 | #endif |
robert_jw | 0:b2805b6888dc | 578 | |
robert_jw | 0:b2805b6888dc | 579 | /** |
robert_jw | 0:b2805b6888dc | 580 | * IP_SOF_BROADCAST=1: Use the SOF_BROADCAST field to enable broadcast |
robert_jw | 0:b2805b6888dc | 581 | * filter per pcb on udp and raw send operations. To enable broadcast filter |
robert_jw | 0:b2805b6888dc | 582 | * on recv operations, you also have to set IP_SOF_BROADCAST_RECV=1. |
robert_jw | 0:b2805b6888dc | 583 | */ |
robert_jw | 0:b2805b6888dc | 584 | #ifndef IP_SOF_BROADCAST |
robert_jw | 0:b2805b6888dc | 585 | #define IP_SOF_BROADCAST 0 |
robert_jw | 0:b2805b6888dc | 586 | #endif |
robert_jw | 0:b2805b6888dc | 587 | |
robert_jw | 0:b2805b6888dc | 588 | /** |
robert_jw | 0:b2805b6888dc | 589 | * IP_SOF_BROADCAST_RECV (requires IP_SOF_BROADCAST=1) enable the broadcast |
robert_jw | 0:b2805b6888dc | 590 | * filter on recv operations. |
robert_jw | 0:b2805b6888dc | 591 | */ |
robert_jw | 0:b2805b6888dc | 592 | #ifndef IP_SOF_BROADCAST_RECV |
robert_jw | 0:b2805b6888dc | 593 | #define IP_SOF_BROADCAST_RECV 0 |
robert_jw | 0:b2805b6888dc | 594 | #endif |
robert_jw | 0:b2805b6888dc | 595 | |
robert_jw | 0:b2805b6888dc | 596 | /* |
robert_jw | 0:b2805b6888dc | 597 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 598 | ---------- ICMP options ---------- |
robert_jw | 0:b2805b6888dc | 599 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 600 | */ |
robert_jw | 0:b2805b6888dc | 601 | /** |
robert_jw | 0:b2805b6888dc | 602 | * LWIP_ICMP==1: Enable ICMP module inside the IP stack. |
robert_jw | 0:b2805b6888dc | 603 | * Be careful, disable that make your product non-compliant to RFC1122 |
robert_jw | 0:b2805b6888dc | 604 | */ |
robert_jw | 0:b2805b6888dc | 605 | #ifndef LWIP_ICMP |
robert_jw | 0:b2805b6888dc | 606 | #define LWIP_ICMP 1 |
robert_jw | 0:b2805b6888dc | 607 | #endif |
robert_jw | 0:b2805b6888dc | 608 | |
robert_jw | 0:b2805b6888dc | 609 | /** |
robert_jw | 0:b2805b6888dc | 610 | * ICMP_TTL: Default value for Time-To-Live used by ICMP packets. |
robert_jw | 0:b2805b6888dc | 611 | */ |
robert_jw | 0:b2805b6888dc | 612 | #ifndef ICMP_TTL |
robert_jw | 0:b2805b6888dc | 613 | #define ICMP_TTL (IP_DEFAULT_TTL) |
robert_jw | 0:b2805b6888dc | 614 | #endif |
robert_jw | 0:b2805b6888dc | 615 | |
robert_jw | 0:b2805b6888dc | 616 | /** |
robert_jw | 0:b2805b6888dc | 617 | * LWIP_BROADCAST_PING==1: respond to broadcast pings (default is unicast only) |
robert_jw | 0:b2805b6888dc | 618 | */ |
robert_jw | 0:b2805b6888dc | 619 | #ifndef LWIP_BROADCAST_PING |
robert_jw | 0:b2805b6888dc | 620 | #define LWIP_BROADCAST_PING 0 |
robert_jw | 0:b2805b6888dc | 621 | #endif |
robert_jw | 0:b2805b6888dc | 622 | |
robert_jw | 0:b2805b6888dc | 623 | /** |
robert_jw | 0:b2805b6888dc | 624 | * LWIP_MULTICAST_PING==1: respond to multicast pings (default is unicast only) |
robert_jw | 0:b2805b6888dc | 625 | */ |
robert_jw | 0:b2805b6888dc | 626 | #ifndef LWIP_MULTICAST_PING |
robert_jw | 0:b2805b6888dc | 627 | #define LWIP_MULTICAST_PING 0 |
robert_jw | 0:b2805b6888dc | 628 | #endif |
robert_jw | 0:b2805b6888dc | 629 | |
robert_jw | 0:b2805b6888dc | 630 | /* |
robert_jw | 0:b2805b6888dc | 631 | --------------------------------- |
robert_jw | 0:b2805b6888dc | 632 | ---------- RAW options ---------- |
robert_jw | 0:b2805b6888dc | 633 | --------------------------------- |
robert_jw | 0:b2805b6888dc | 634 | */ |
robert_jw | 0:b2805b6888dc | 635 | /** |
robert_jw | 0:b2805b6888dc | 636 | * LWIP_RAW==1: Enable application layer to hook into the IP layer itself. |
robert_jw | 0:b2805b6888dc | 637 | */ |
robert_jw | 0:b2805b6888dc | 638 | #ifndef LWIP_RAW |
robert_jw | 0:b2805b6888dc | 639 | #define LWIP_RAW 1 |
robert_jw | 0:b2805b6888dc | 640 | #endif |
robert_jw | 0:b2805b6888dc | 641 | |
robert_jw | 0:b2805b6888dc | 642 | /** |
robert_jw | 0:b2805b6888dc | 643 | * LWIP_RAW==1: Enable application layer to hook into the IP layer itself. |
robert_jw | 0:b2805b6888dc | 644 | */ |
robert_jw | 0:b2805b6888dc | 645 | #ifndef RAW_TTL |
robert_jw | 0:b2805b6888dc | 646 | #define RAW_TTL (IP_DEFAULT_TTL) |
robert_jw | 0:b2805b6888dc | 647 | #endif |
robert_jw | 0:b2805b6888dc | 648 | |
robert_jw | 0:b2805b6888dc | 649 | /* |
robert_jw | 0:b2805b6888dc | 650 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 651 | ---------- DHCP options ---------- |
robert_jw | 0:b2805b6888dc | 652 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 653 | */ |
robert_jw | 0:b2805b6888dc | 654 | /** |
robert_jw | 0:b2805b6888dc | 655 | * LWIP_DHCP==1: Enable DHCP module. |
robert_jw | 0:b2805b6888dc | 656 | */ |
robert_jw | 0:b2805b6888dc | 657 | #ifndef LWIP_DHCP |
robert_jw | 0:b2805b6888dc | 658 | #define LWIP_DHCP 0 |
robert_jw | 0:b2805b6888dc | 659 | #endif |
robert_jw | 0:b2805b6888dc | 660 | |
robert_jw | 0:b2805b6888dc | 661 | /** |
robert_jw | 0:b2805b6888dc | 662 | * DHCP_DOES_ARP_CHECK==1: Do an ARP check on the offered address. |
robert_jw | 0:b2805b6888dc | 663 | */ |
robert_jw | 0:b2805b6888dc | 664 | #ifndef DHCP_DOES_ARP_CHECK |
robert_jw | 0:b2805b6888dc | 665 | #define DHCP_DOES_ARP_CHECK ((LWIP_DHCP) && (LWIP_ARP)) |
robert_jw | 0:b2805b6888dc | 666 | #endif |
robert_jw | 0:b2805b6888dc | 667 | |
robert_jw | 0:b2805b6888dc | 668 | /* |
robert_jw | 0:b2805b6888dc | 669 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 670 | ---------- AUTOIP options ---------- |
robert_jw | 0:b2805b6888dc | 671 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 672 | */ |
robert_jw | 0:b2805b6888dc | 673 | /** |
robert_jw | 0:b2805b6888dc | 674 | * LWIP_AUTOIP==1: Enable AUTOIP module. |
robert_jw | 0:b2805b6888dc | 675 | */ |
robert_jw | 0:b2805b6888dc | 676 | #ifndef LWIP_AUTOIP |
robert_jw | 0:b2805b6888dc | 677 | #define LWIP_AUTOIP 0 |
robert_jw | 0:b2805b6888dc | 678 | #endif |
robert_jw | 0:b2805b6888dc | 679 | |
robert_jw | 0:b2805b6888dc | 680 | /** |
robert_jw | 0:b2805b6888dc | 681 | * LWIP_DHCP_AUTOIP_COOP==1: Allow DHCP and AUTOIP to be both enabled on |
robert_jw | 0:b2805b6888dc | 682 | * the same interface at the same time. |
robert_jw | 0:b2805b6888dc | 683 | */ |
robert_jw | 0:b2805b6888dc | 684 | #ifndef LWIP_DHCP_AUTOIP_COOP |
robert_jw | 0:b2805b6888dc | 685 | #define LWIP_DHCP_AUTOIP_COOP 0 |
robert_jw | 0:b2805b6888dc | 686 | #endif |
robert_jw | 0:b2805b6888dc | 687 | |
robert_jw | 0:b2805b6888dc | 688 | /** |
robert_jw | 0:b2805b6888dc | 689 | * LWIP_DHCP_AUTOIP_COOP_TRIES: Set to the number of DHCP DISCOVER probes |
robert_jw | 0:b2805b6888dc | 690 | * that should be sent before falling back on AUTOIP. This can be set |
robert_jw | 0:b2805b6888dc | 691 | * as low as 1 to get an AutoIP address very quickly, but you should |
robert_jw | 0:b2805b6888dc | 692 | * be prepared to handle a changing IP address when DHCP overrides |
robert_jw | 0:b2805b6888dc | 693 | * AutoIP. |
robert_jw | 0:b2805b6888dc | 694 | */ |
robert_jw | 0:b2805b6888dc | 695 | #ifndef LWIP_DHCP_AUTOIP_COOP_TRIES |
robert_jw | 0:b2805b6888dc | 696 | #define LWIP_DHCP_AUTOIP_COOP_TRIES 9 |
robert_jw | 0:b2805b6888dc | 697 | #endif |
robert_jw | 0:b2805b6888dc | 698 | |
robert_jw | 0:b2805b6888dc | 699 | /* |
robert_jw | 0:b2805b6888dc | 700 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 701 | ---------- SNMP options ---------- |
robert_jw | 0:b2805b6888dc | 702 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 703 | */ |
robert_jw | 0:b2805b6888dc | 704 | /** |
robert_jw | 0:b2805b6888dc | 705 | * LWIP_SNMP==1: Turn on SNMP module. UDP must be available for SNMP |
robert_jw | 0:b2805b6888dc | 706 | * transport. |
robert_jw | 0:b2805b6888dc | 707 | */ |
robert_jw | 0:b2805b6888dc | 708 | #ifndef LWIP_SNMP |
robert_jw | 0:b2805b6888dc | 709 | #define LWIP_SNMP 0 |
robert_jw | 0:b2805b6888dc | 710 | #endif |
robert_jw | 0:b2805b6888dc | 711 | |
robert_jw | 0:b2805b6888dc | 712 | /** |
robert_jw | 0:b2805b6888dc | 713 | * SNMP_CONCURRENT_REQUESTS: Number of concurrent requests the module will |
robert_jw | 0:b2805b6888dc | 714 | * allow. At least one request buffer is required. |
robert_jw | 0:b2805b6888dc | 715 | * Does not have to be changed unless external MIBs answer request asynchronously |
robert_jw | 0:b2805b6888dc | 716 | */ |
robert_jw | 0:b2805b6888dc | 717 | #ifndef SNMP_CONCURRENT_REQUESTS |
robert_jw | 0:b2805b6888dc | 718 | #define SNMP_CONCURRENT_REQUESTS 1 |
robert_jw | 0:b2805b6888dc | 719 | #endif |
robert_jw | 0:b2805b6888dc | 720 | |
robert_jw | 0:b2805b6888dc | 721 | /** |
robert_jw | 0:b2805b6888dc | 722 | * SNMP_TRAP_DESTINATIONS: Number of trap destinations. At least one trap |
robert_jw | 0:b2805b6888dc | 723 | * destination is required |
robert_jw | 0:b2805b6888dc | 724 | */ |
robert_jw | 0:b2805b6888dc | 725 | #ifndef SNMP_TRAP_DESTINATIONS |
robert_jw | 0:b2805b6888dc | 726 | #define SNMP_TRAP_DESTINATIONS 1 |
robert_jw | 0:b2805b6888dc | 727 | #endif |
robert_jw | 0:b2805b6888dc | 728 | |
robert_jw | 0:b2805b6888dc | 729 | /** |
robert_jw | 0:b2805b6888dc | 730 | * SNMP_PRIVATE_MIB: |
robert_jw | 0:b2805b6888dc | 731 | * When using a private MIB, you have to create a file 'private_mib.h' that contains |
robert_jw | 0:b2805b6888dc | 732 | * a 'struct mib_array_node mib_private' which contains your MIB. |
robert_jw | 0:b2805b6888dc | 733 | */ |
robert_jw | 0:b2805b6888dc | 734 | #ifndef SNMP_PRIVATE_MIB |
robert_jw | 0:b2805b6888dc | 735 | #define SNMP_PRIVATE_MIB 0 |
robert_jw | 0:b2805b6888dc | 736 | #endif |
robert_jw | 0:b2805b6888dc | 737 | |
robert_jw | 0:b2805b6888dc | 738 | /** |
robert_jw | 0:b2805b6888dc | 739 | * Only allow SNMP write actions that are 'safe' (e.g. disabeling netifs is not |
robert_jw | 0:b2805b6888dc | 740 | * a safe action and disabled when SNMP_SAFE_REQUESTS = 1). |
robert_jw | 0:b2805b6888dc | 741 | * Unsafe requests are disabled by default! |
robert_jw | 0:b2805b6888dc | 742 | */ |
robert_jw | 0:b2805b6888dc | 743 | #ifndef SNMP_SAFE_REQUESTS |
robert_jw | 0:b2805b6888dc | 744 | #define SNMP_SAFE_REQUESTS 1 |
robert_jw | 0:b2805b6888dc | 745 | #endif |
robert_jw | 0:b2805b6888dc | 746 | |
robert_jw | 0:b2805b6888dc | 747 | /** |
robert_jw | 0:b2805b6888dc | 748 | * The maximum length of strings used. This affects the size of |
robert_jw | 0:b2805b6888dc | 749 | * MEMP_SNMP_VALUE elements. |
robert_jw | 0:b2805b6888dc | 750 | */ |
robert_jw | 0:b2805b6888dc | 751 | #ifndef SNMP_MAX_OCTET_STRING_LEN |
robert_jw | 0:b2805b6888dc | 752 | #define SNMP_MAX_OCTET_STRING_LEN 127 |
robert_jw | 0:b2805b6888dc | 753 | #endif |
robert_jw | 0:b2805b6888dc | 754 | |
robert_jw | 0:b2805b6888dc | 755 | /** |
robert_jw | 0:b2805b6888dc | 756 | * The maximum depth of the SNMP tree. |
robert_jw | 0:b2805b6888dc | 757 | * With private MIBs enabled, this depends on your MIB! |
robert_jw | 0:b2805b6888dc | 758 | * This affects the size of MEMP_SNMP_VALUE elements. |
robert_jw | 0:b2805b6888dc | 759 | */ |
robert_jw | 0:b2805b6888dc | 760 | #ifndef SNMP_MAX_TREE_DEPTH |
robert_jw | 0:b2805b6888dc | 761 | #define SNMP_MAX_TREE_DEPTH 15 |
robert_jw | 0:b2805b6888dc | 762 | #endif |
robert_jw | 0:b2805b6888dc | 763 | |
robert_jw | 0:b2805b6888dc | 764 | /** |
robert_jw | 0:b2805b6888dc | 765 | * The size of the MEMP_SNMP_VALUE elements, normally calculated from |
robert_jw | 0:b2805b6888dc | 766 | * SNMP_MAX_OCTET_STRING_LEN and SNMP_MAX_TREE_DEPTH. |
robert_jw | 0:b2805b6888dc | 767 | */ |
robert_jw | 0:b2805b6888dc | 768 | #ifndef SNMP_MAX_VALUE_SIZE |
robert_jw | 0:b2805b6888dc | 769 | #define SNMP_MAX_VALUE_SIZE LWIP_MAX((SNMP_MAX_OCTET_STRING_LEN)+1, sizeof(s32_t)*(SNMP_MAX_TREE_DEPTH)) |
robert_jw | 0:b2805b6888dc | 770 | #endif |
robert_jw | 0:b2805b6888dc | 771 | |
robert_jw | 0:b2805b6888dc | 772 | /* |
robert_jw | 0:b2805b6888dc | 773 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 774 | ---------- IGMP options ---------- |
robert_jw | 0:b2805b6888dc | 775 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 776 | */ |
robert_jw | 0:b2805b6888dc | 777 | /** |
robert_jw | 0:b2805b6888dc | 778 | * LWIP_IGMP==1: Turn on IGMP module. |
robert_jw | 0:b2805b6888dc | 779 | */ |
robert_jw | 0:b2805b6888dc | 780 | #ifndef LWIP_IGMP |
robert_jw | 0:b2805b6888dc | 781 | #define LWIP_IGMP 0 |
robert_jw | 0:b2805b6888dc | 782 | #endif |
robert_jw | 0:b2805b6888dc | 783 | |
robert_jw | 0:b2805b6888dc | 784 | /* |
robert_jw | 0:b2805b6888dc | 785 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 786 | ---------- DNS options ----------- |
robert_jw | 0:b2805b6888dc | 787 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 788 | */ |
robert_jw | 0:b2805b6888dc | 789 | /** |
robert_jw | 0:b2805b6888dc | 790 | * LWIP_DNS==1: Turn on DNS module. UDP must be available for DNS |
robert_jw | 0:b2805b6888dc | 791 | * transport. |
robert_jw | 0:b2805b6888dc | 792 | */ |
robert_jw | 0:b2805b6888dc | 793 | #ifndef LWIP_DNS |
robert_jw | 0:b2805b6888dc | 794 | #define LWIP_DNS 0 |
robert_jw | 0:b2805b6888dc | 795 | #endif |
robert_jw | 0:b2805b6888dc | 796 | |
robert_jw | 0:b2805b6888dc | 797 | /** DNS maximum number of entries to maintain locally. */ |
robert_jw | 0:b2805b6888dc | 798 | #ifndef DNS_TABLE_SIZE |
robert_jw | 0:b2805b6888dc | 799 | #define DNS_TABLE_SIZE 4 |
robert_jw | 0:b2805b6888dc | 800 | #endif |
robert_jw | 0:b2805b6888dc | 801 | |
robert_jw | 0:b2805b6888dc | 802 | /** DNS maximum host name length supported in the name table. */ |
robert_jw | 0:b2805b6888dc | 803 | #ifndef DNS_MAX_NAME_LENGTH |
robert_jw | 0:b2805b6888dc | 804 | #define DNS_MAX_NAME_LENGTH 256 |
robert_jw | 0:b2805b6888dc | 805 | #endif |
robert_jw | 0:b2805b6888dc | 806 | |
robert_jw | 0:b2805b6888dc | 807 | /** The maximum of DNS servers */ |
robert_jw | 0:b2805b6888dc | 808 | #ifndef DNS_MAX_SERVERS |
robert_jw | 0:b2805b6888dc | 809 | #define DNS_MAX_SERVERS 2 |
robert_jw | 0:b2805b6888dc | 810 | #endif |
robert_jw | 0:b2805b6888dc | 811 | |
robert_jw | 0:b2805b6888dc | 812 | /** DNS do a name checking between the query and the response. */ |
robert_jw | 0:b2805b6888dc | 813 | #ifndef DNS_DOES_NAME_CHECK |
robert_jw | 0:b2805b6888dc | 814 | #define DNS_DOES_NAME_CHECK 1 |
robert_jw | 0:b2805b6888dc | 815 | #endif |
robert_jw | 0:b2805b6888dc | 816 | |
robert_jw | 0:b2805b6888dc | 817 | /** DNS message max. size. Default value is RFC compliant. */ |
robert_jw | 0:b2805b6888dc | 818 | #ifndef DNS_MSG_SIZE |
robert_jw | 0:b2805b6888dc | 819 | #define DNS_MSG_SIZE 512 |
robert_jw | 0:b2805b6888dc | 820 | #endif |
robert_jw | 0:b2805b6888dc | 821 | |
robert_jw | 0:b2805b6888dc | 822 | /** DNS_LOCAL_HOSTLIST: Implements a local host-to-address list. If enabled, |
robert_jw | 0:b2805b6888dc | 823 | * you have to define |
robert_jw | 0:b2805b6888dc | 824 | * #define DNS_LOCAL_HOSTLIST_INIT {{"host1", 0x123}, {"host2", 0x234}} |
robert_jw | 0:b2805b6888dc | 825 | * (an array of structs name/address, where address is an u32_t in network |
robert_jw | 0:b2805b6888dc | 826 | * byte order). |
robert_jw | 0:b2805b6888dc | 827 | * |
robert_jw | 0:b2805b6888dc | 828 | * Instead, you can also use an external function: |
robert_jw | 0:b2805b6888dc | 829 | * #define DNS_LOOKUP_LOCAL_EXTERN(x) extern u32_t my_lookup_function(const char *name) |
robert_jw | 0:b2805b6888dc | 830 | * that returns the IP address or INADDR_NONE if not found. |
robert_jw | 0:b2805b6888dc | 831 | */ |
robert_jw | 0:b2805b6888dc | 832 | #ifndef DNS_LOCAL_HOSTLIST |
robert_jw | 0:b2805b6888dc | 833 | #define DNS_LOCAL_HOSTLIST 0 |
robert_jw | 0:b2805b6888dc | 834 | #endif /* DNS_LOCAL_HOSTLIST */ |
robert_jw | 0:b2805b6888dc | 835 | |
robert_jw | 0:b2805b6888dc | 836 | /** If this is turned on, the local host-list can be dynamically changed |
robert_jw | 0:b2805b6888dc | 837 | * at runtime. */ |
robert_jw | 0:b2805b6888dc | 838 | #ifndef DNS_LOCAL_HOSTLIST_IS_DYNAMIC |
robert_jw | 0:b2805b6888dc | 839 | #define DNS_LOCAL_HOSTLIST_IS_DYNAMIC 0 |
robert_jw | 0:b2805b6888dc | 840 | #endif /* DNS_LOCAL_HOSTLIST_IS_DYNAMIC */ |
robert_jw | 0:b2805b6888dc | 841 | |
robert_jw | 0:b2805b6888dc | 842 | /* |
robert_jw | 0:b2805b6888dc | 843 | --------------------------------- |
robert_jw | 0:b2805b6888dc | 844 | ---------- UDP options ---------- |
robert_jw | 0:b2805b6888dc | 845 | --------------------------------- |
robert_jw | 0:b2805b6888dc | 846 | */ |
robert_jw | 0:b2805b6888dc | 847 | /** |
robert_jw | 0:b2805b6888dc | 848 | * LWIP_UDP==1: Turn on UDP. |
robert_jw | 0:b2805b6888dc | 849 | */ |
robert_jw | 0:b2805b6888dc | 850 | #ifndef LWIP_UDP |
robert_jw | 0:b2805b6888dc | 851 | #define LWIP_UDP 1 |
robert_jw | 0:b2805b6888dc | 852 | #endif |
robert_jw | 0:b2805b6888dc | 853 | |
robert_jw | 0:b2805b6888dc | 854 | /** |
robert_jw | 0:b2805b6888dc | 855 | * LWIP_UDPLITE==1: Turn on UDP-Lite. (Requires LWIP_UDP) |
robert_jw | 0:b2805b6888dc | 856 | */ |
robert_jw | 0:b2805b6888dc | 857 | #ifndef LWIP_UDPLITE |
robert_jw | 0:b2805b6888dc | 858 | #define LWIP_UDPLITE 0 |
robert_jw | 0:b2805b6888dc | 859 | #endif |
robert_jw | 0:b2805b6888dc | 860 | |
robert_jw | 0:b2805b6888dc | 861 | /** |
robert_jw | 0:b2805b6888dc | 862 | * UDP_TTL: Default Time-To-Live value. |
robert_jw | 0:b2805b6888dc | 863 | */ |
robert_jw | 0:b2805b6888dc | 864 | #ifndef UDP_TTL |
robert_jw | 0:b2805b6888dc | 865 | #define UDP_TTL (IP_DEFAULT_TTL) |
robert_jw | 0:b2805b6888dc | 866 | #endif |
robert_jw | 0:b2805b6888dc | 867 | |
robert_jw | 0:b2805b6888dc | 868 | /** |
robert_jw | 0:b2805b6888dc | 869 | * LWIP_NETBUF_RECVINFO==1: append destination addr and port to every netbuf. |
robert_jw | 0:b2805b6888dc | 870 | */ |
robert_jw | 0:b2805b6888dc | 871 | #ifndef LWIP_NETBUF_RECVINFO |
robert_jw | 0:b2805b6888dc | 872 | #define LWIP_NETBUF_RECVINFO 0 |
robert_jw | 0:b2805b6888dc | 873 | #endif |
robert_jw | 0:b2805b6888dc | 874 | |
robert_jw | 0:b2805b6888dc | 875 | /* |
robert_jw | 0:b2805b6888dc | 876 | --------------------------------- |
robert_jw | 0:b2805b6888dc | 877 | ---------- TCP options ---------- |
robert_jw | 0:b2805b6888dc | 878 | --------------------------------- |
robert_jw | 0:b2805b6888dc | 879 | */ |
robert_jw | 0:b2805b6888dc | 880 | /** |
robert_jw | 0:b2805b6888dc | 881 | * LWIP_TCP==1: Turn on TCP. |
robert_jw | 0:b2805b6888dc | 882 | */ |
robert_jw | 0:b2805b6888dc | 883 | #ifndef LWIP_TCP |
robert_jw | 0:b2805b6888dc | 884 | #define LWIP_TCP 1 |
robert_jw | 0:b2805b6888dc | 885 | #endif |
robert_jw | 0:b2805b6888dc | 886 | |
robert_jw | 0:b2805b6888dc | 887 | /** |
robert_jw | 0:b2805b6888dc | 888 | * TCP_TTL: Default Time-To-Live value. |
robert_jw | 0:b2805b6888dc | 889 | */ |
robert_jw | 0:b2805b6888dc | 890 | #ifndef TCP_TTL |
robert_jw | 0:b2805b6888dc | 891 | #define TCP_TTL (IP_DEFAULT_TTL) |
robert_jw | 0:b2805b6888dc | 892 | #endif |
robert_jw | 0:b2805b6888dc | 893 | |
robert_jw | 0:b2805b6888dc | 894 | /** |
robert_jw | 0:b2805b6888dc | 895 | * TCP_WND: The size of a TCP window. This must be at least |
robert_jw | 0:b2805b6888dc | 896 | * (2 * TCP_MSS) for things to work well |
robert_jw | 0:b2805b6888dc | 897 | */ |
robert_jw | 0:b2805b6888dc | 898 | #ifndef TCP_WND |
robert_jw | 0:b2805b6888dc | 899 | #define TCP_WND (4 * TCP_MSS) |
robert_jw | 0:b2805b6888dc | 900 | #endif |
robert_jw | 0:b2805b6888dc | 901 | |
robert_jw | 0:b2805b6888dc | 902 | /** |
robert_jw | 0:b2805b6888dc | 903 | * TCP_MAXRTX: Maximum number of retransmissions of data segments. |
robert_jw | 0:b2805b6888dc | 904 | */ |
robert_jw | 0:b2805b6888dc | 905 | #ifndef TCP_MAXRTX |
robert_jw | 0:b2805b6888dc | 906 | #define TCP_MAXRTX 12 |
robert_jw | 0:b2805b6888dc | 907 | #endif |
robert_jw | 0:b2805b6888dc | 908 | |
robert_jw | 0:b2805b6888dc | 909 | /** |
robert_jw | 0:b2805b6888dc | 910 | * TCP_SYNMAXRTX: Maximum number of retransmissions of SYN segments. |
robert_jw | 0:b2805b6888dc | 911 | */ |
robert_jw | 0:b2805b6888dc | 912 | #ifndef TCP_SYNMAXRTX |
robert_jw | 0:b2805b6888dc | 913 | #define TCP_SYNMAXRTX 6 |
robert_jw | 0:b2805b6888dc | 914 | #endif |
robert_jw | 0:b2805b6888dc | 915 | |
robert_jw | 0:b2805b6888dc | 916 | /** |
robert_jw | 0:b2805b6888dc | 917 | * TCP_QUEUE_OOSEQ==1: TCP will queue segments that arrive out of order. |
robert_jw | 0:b2805b6888dc | 918 | * Define to 0 if your device is low on memory. |
robert_jw | 0:b2805b6888dc | 919 | */ |
robert_jw | 0:b2805b6888dc | 920 | #ifndef TCP_QUEUE_OOSEQ |
robert_jw | 0:b2805b6888dc | 921 | #define TCP_QUEUE_OOSEQ (LWIP_TCP) |
robert_jw | 0:b2805b6888dc | 922 | #endif |
robert_jw | 0:b2805b6888dc | 923 | |
robert_jw | 0:b2805b6888dc | 924 | /** |
robert_jw | 0:b2805b6888dc | 925 | * TCP_MSS: TCP Maximum segment size. (default is 536, a conservative default, |
robert_jw | 0:b2805b6888dc | 926 | * you might want to increase this.) |
robert_jw | 0:b2805b6888dc | 927 | * For the receive side, this MSS is advertised to the remote side |
robert_jw | 0:b2805b6888dc | 928 | * when opening a connection. For the transmit size, this MSS sets |
robert_jw | 0:b2805b6888dc | 929 | * an upper limit on the MSS advertised by the remote host. |
robert_jw | 0:b2805b6888dc | 930 | */ |
robert_jw | 0:b2805b6888dc | 931 | #ifndef TCP_MSS |
robert_jw | 0:b2805b6888dc | 932 | #define TCP_MSS 536 |
robert_jw | 0:b2805b6888dc | 933 | #endif |
robert_jw | 0:b2805b6888dc | 934 | |
robert_jw | 0:b2805b6888dc | 935 | /** |
robert_jw | 0:b2805b6888dc | 936 | * TCP_CALCULATE_EFF_SEND_MSS: "The maximum size of a segment that TCP really |
robert_jw | 0:b2805b6888dc | 937 | * sends, the 'effective send MSS,' MUST be the smaller of the send MSS (which |
robert_jw | 0:b2805b6888dc | 938 | * reflects the available reassembly buffer size at the remote host) and the |
robert_jw | 0:b2805b6888dc | 939 | * largest size permitted by the IP layer" (RFC 1122) |
robert_jw | 0:b2805b6888dc | 940 | * Setting this to 1 enables code that checks TCP_MSS against the MTU of the |
robert_jw | 0:b2805b6888dc | 941 | * netif used for a connection and limits the MSS if it would be too big otherwise. |
robert_jw | 0:b2805b6888dc | 942 | */ |
robert_jw | 0:b2805b6888dc | 943 | #ifndef TCP_CALCULATE_EFF_SEND_MSS |
robert_jw | 0:b2805b6888dc | 944 | #define TCP_CALCULATE_EFF_SEND_MSS 1 |
robert_jw | 0:b2805b6888dc | 945 | #endif |
robert_jw | 0:b2805b6888dc | 946 | |
robert_jw | 0:b2805b6888dc | 947 | |
robert_jw | 0:b2805b6888dc | 948 | /** |
robert_jw | 0:b2805b6888dc | 949 | * TCP_SND_BUF: TCP sender buffer space (bytes). |
robert_jw | 0:b2805b6888dc | 950 | */ |
robert_jw | 0:b2805b6888dc | 951 | #ifndef TCP_SND_BUF |
robert_jw | 0:b2805b6888dc | 952 | #define TCP_SND_BUF 256 |
robert_jw | 0:b2805b6888dc | 953 | #endif |
robert_jw | 0:b2805b6888dc | 954 | |
robert_jw | 0:b2805b6888dc | 955 | /** |
robert_jw | 0:b2805b6888dc | 956 | * TCP_SND_QUEUELEN: TCP sender buffer space (pbufs). This must be at least |
robert_jw | 0:b2805b6888dc | 957 | * as much as (2 * TCP_SND_BUF/TCP_MSS) for things to work. |
robert_jw | 0:b2805b6888dc | 958 | */ |
robert_jw | 0:b2805b6888dc | 959 | #ifndef TCP_SND_QUEUELEN |
robert_jw | 0:b2805b6888dc | 960 | #define TCP_SND_QUEUELEN ((4 * (TCP_SND_BUF) + (TCP_MSS - 1))/(TCP_MSS)) |
robert_jw | 0:b2805b6888dc | 961 | #endif |
robert_jw | 0:b2805b6888dc | 962 | |
robert_jw | 0:b2805b6888dc | 963 | /** |
robert_jw | 0:b2805b6888dc | 964 | * TCP_SNDLOWAT: TCP writable space (bytes). This must be less than |
robert_jw | 0:b2805b6888dc | 965 | * TCP_SND_BUF. It is the amount of space which must be available in the |
robert_jw | 0:b2805b6888dc | 966 | * TCP snd_buf for select to return writable (combined with TCP_SNDQUEUELOWAT). |
robert_jw | 0:b2805b6888dc | 967 | */ |
robert_jw | 0:b2805b6888dc | 968 | #ifndef TCP_SNDLOWAT |
robert_jw | 0:b2805b6888dc | 969 | #define TCP_SNDLOWAT ((TCP_SND_BUF)/2) |
robert_jw | 0:b2805b6888dc | 970 | #endif |
robert_jw | 0:b2805b6888dc | 971 | |
robert_jw | 0:b2805b6888dc | 972 | /** |
robert_jw | 0:b2805b6888dc | 973 | * TCP_SNDQUEUELOWAT: TCP writable bufs (pbuf count). This must be grater |
robert_jw | 0:b2805b6888dc | 974 | * than TCP_SND_QUEUELEN. If the number of pbufs queued on a pcb drops below |
robert_jw | 0:b2805b6888dc | 975 | * this number, select returns writable (combined with TCP_SNDLOWAT). |
robert_jw | 0:b2805b6888dc | 976 | */ |
robert_jw | 0:b2805b6888dc | 977 | #ifndef TCP_SNDQUEUELOWAT |
robert_jw | 0:b2805b6888dc | 978 | #define TCP_SNDQUEUELOWAT ((TCP_SND_QUEUELEN)/2) |
robert_jw | 0:b2805b6888dc | 979 | #endif |
robert_jw | 0:b2805b6888dc | 980 | |
robert_jw | 0:b2805b6888dc | 981 | /** |
robert_jw | 0:b2805b6888dc | 982 | * TCP_LISTEN_BACKLOG: Enable the backlog option for tcp listen pcb. |
robert_jw | 0:b2805b6888dc | 983 | */ |
robert_jw | 0:b2805b6888dc | 984 | #ifndef TCP_LISTEN_BACKLOG |
robert_jw | 0:b2805b6888dc | 985 | #define TCP_LISTEN_BACKLOG 0 |
robert_jw | 0:b2805b6888dc | 986 | #endif |
robert_jw | 0:b2805b6888dc | 987 | |
robert_jw | 0:b2805b6888dc | 988 | /** |
robert_jw | 0:b2805b6888dc | 989 | * The maximum allowed backlog for TCP listen netconns. |
robert_jw | 0:b2805b6888dc | 990 | * This backlog is used unless another is explicitly specified. |
robert_jw | 0:b2805b6888dc | 991 | * 0xff is the maximum (u8_t). |
robert_jw | 0:b2805b6888dc | 992 | */ |
robert_jw | 0:b2805b6888dc | 993 | #ifndef TCP_DEFAULT_LISTEN_BACKLOG |
robert_jw | 0:b2805b6888dc | 994 | #define TCP_DEFAULT_LISTEN_BACKLOG 0xff |
robert_jw | 0:b2805b6888dc | 995 | #endif |
robert_jw | 0:b2805b6888dc | 996 | |
robert_jw | 0:b2805b6888dc | 997 | /** |
robert_jw | 0:b2805b6888dc | 998 | * TCP_OVERSIZE: The maximum number of bytes that tcp_write may |
robert_jw | 0:b2805b6888dc | 999 | * allocate ahead of time in an attempt to create shorter pbuf chains |
robert_jw | 0:b2805b6888dc | 1000 | * for transmission. The meaningful range is 0 to TCP_MSS. Some |
robert_jw | 0:b2805b6888dc | 1001 | * suggested values are: |
robert_jw | 0:b2805b6888dc | 1002 | * |
robert_jw | 0:b2805b6888dc | 1003 | * 0: Disable oversized allocation. Each tcp_write() allocates a new |
robert_jw | 0:b2805b6888dc | 1004 | pbuf (old behaviour). |
robert_jw | 0:b2805b6888dc | 1005 | * 1: Allocate size-aligned pbufs with minimal excess. Use this if your |
robert_jw | 0:b2805b6888dc | 1006 | * scatter-gather DMA requires aligned fragments. |
robert_jw | 0:b2805b6888dc | 1007 | * 128: Limit the pbuf/memory overhead to 20%. |
robert_jw | 0:b2805b6888dc | 1008 | * TCP_MSS: Try to create unfragmented TCP packets. |
robert_jw | 0:b2805b6888dc | 1009 | * TCP_MSS/4: Try to create 4 fragments or less per TCP packet. |
robert_jw | 0:b2805b6888dc | 1010 | */ |
robert_jw | 0:b2805b6888dc | 1011 | #ifndef TCP_OVERSIZE |
robert_jw | 0:b2805b6888dc | 1012 | #define TCP_OVERSIZE TCP_MSS |
robert_jw | 0:b2805b6888dc | 1013 | #endif |
robert_jw | 0:b2805b6888dc | 1014 | |
robert_jw | 0:b2805b6888dc | 1015 | /** |
robert_jw | 0:b2805b6888dc | 1016 | * LWIP_TCP_TIMESTAMPS==1: support the TCP timestamp option. |
robert_jw | 0:b2805b6888dc | 1017 | */ |
robert_jw | 0:b2805b6888dc | 1018 | #ifndef LWIP_TCP_TIMESTAMPS |
robert_jw | 0:b2805b6888dc | 1019 | #define LWIP_TCP_TIMESTAMPS 0 |
robert_jw | 0:b2805b6888dc | 1020 | #endif |
robert_jw | 0:b2805b6888dc | 1021 | |
robert_jw | 0:b2805b6888dc | 1022 | /** |
robert_jw | 0:b2805b6888dc | 1023 | * TCP_WND_UPDATE_THRESHOLD: difference in window to trigger an |
robert_jw | 0:b2805b6888dc | 1024 | * explicit window update |
robert_jw | 0:b2805b6888dc | 1025 | */ |
robert_jw | 0:b2805b6888dc | 1026 | #ifndef TCP_WND_UPDATE_THRESHOLD |
robert_jw | 0:b2805b6888dc | 1027 | #define TCP_WND_UPDATE_THRESHOLD (TCP_WND / 4) |
robert_jw | 0:b2805b6888dc | 1028 | #endif |
robert_jw | 0:b2805b6888dc | 1029 | |
robert_jw | 0:b2805b6888dc | 1030 | /** |
robert_jw | 0:b2805b6888dc | 1031 | * LWIP_EVENT_API and LWIP_CALLBACK_API: Only one of these should be set to 1. |
robert_jw | 0:b2805b6888dc | 1032 | * LWIP_EVENT_API==1: The user defines lwip_tcp_event() to receive all |
robert_jw | 0:b2805b6888dc | 1033 | * events (accept, sent, etc) that happen in the system. |
robert_jw | 0:b2805b6888dc | 1034 | * LWIP_CALLBACK_API==1: The PCB callback function is called directly |
robert_jw | 0:b2805b6888dc | 1035 | * for the event. |
robert_jw | 0:b2805b6888dc | 1036 | */ |
robert_jw | 0:b2805b6888dc | 1037 | #ifndef LWIP_EVENT_API |
robert_jw | 0:b2805b6888dc | 1038 | #define LWIP_EVENT_API 0 |
robert_jw | 0:b2805b6888dc | 1039 | #define LWIP_CALLBACK_API 1 |
robert_jw | 0:b2805b6888dc | 1040 | #else |
robert_jw | 0:b2805b6888dc | 1041 | #define LWIP_EVENT_API 1 |
robert_jw | 0:b2805b6888dc | 1042 | #define LWIP_CALLBACK_API 0 |
robert_jw | 0:b2805b6888dc | 1043 | #endif |
robert_jw | 0:b2805b6888dc | 1044 | |
robert_jw | 0:b2805b6888dc | 1045 | |
robert_jw | 0:b2805b6888dc | 1046 | /* |
robert_jw | 0:b2805b6888dc | 1047 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 1048 | ---------- Pbuf options ---------- |
robert_jw | 0:b2805b6888dc | 1049 | ---------------------------------- |
robert_jw | 0:b2805b6888dc | 1050 | */ |
robert_jw | 0:b2805b6888dc | 1051 | /** |
robert_jw | 0:b2805b6888dc | 1052 | * PBUF_LINK_HLEN: the number of bytes that should be allocated for a |
robert_jw | 0:b2805b6888dc | 1053 | * link level header. The default is 14, the standard value for |
robert_jw | 0:b2805b6888dc | 1054 | * Ethernet. |
robert_jw | 0:b2805b6888dc | 1055 | */ |
robert_jw | 0:b2805b6888dc | 1056 | #ifndef PBUF_LINK_HLEN |
robert_jw | 0:b2805b6888dc | 1057 | #define PBUF_LINK_HLEN (14 + ETH_PAD_SIZE) |
robert_jw | 0:b2805b6888dc | 1058 | #endif |
robert_jw | 0:b2805b6888dc | 1059 | |
robert_jw | 0:b2805b6888dc | 1060 | /** |
robert_jw | 0:b2805b6888dc | 1061 | * PBUF_POOL_BUFSIZE: the size of each pbuf in the pbuf pool. The default is |
robert_jw | 0:b2805b6888dc | 1062 | * designed to accomodate single full size TCP frame in one pbuf, including |
robert_jw | 0:b2805b6888dc | 1063 | * TCP_MSS, IP header, and link header. |
robert_jw | 0:b2805b6888dc | 1064 | */ |
robert_jw | 0:b2805b6888dc | 1065 | #ifndef PBUF_POOL_BUFSIZE |
robert_jw | 0:b2805b6888dc | 1066 | #define PBUF_POOL_BUFSIZE LWIP_MEM_ALIGN_SIZE(TCP_MSS+40+PBUF_LINK_HLEN) |
robert_jw | 0:b2805b6888dc | 1067 | #endif |
robert_jw | 0:b2805b6888dc | 1068 | |
robert_jw | 0:b2805b6888dc | 1069 | /* |
robert_jw | 0:b2805b6888dc | 1070 | ------------------------------------------------ |
robert_jw | 0:b2805b6888dc | 1071 | ---------- Network Interfaces options ---------- |
robert_jw | 0:b2805b6888dc | 1072 | ------------------------------------------------ |
robert_jw | 0:b2805b6888dc | 1073 | */ |
robert_jw | 0:b2805b6888dc | 1074 | /** |
robert_jw | 0:b2805b6888dc | 1075 | * LWIP_NETIF_HOSTNAME==1: use DHCP_OPTION_HOSTNAME with netif's hostname |
robert_jw | 0:b2805b6888dc | 1076 | * field. |
robert_jw | 0:b2805b6888dc | 1077 | */ |
robert_jw | 0:b2805b6888dc | 1078 | #ifndef LWIP_NETIF_HOSTNAME |
robert_jw | 0:b2805b6888dc | 1079 | #define LWIP_NETIF_HOSTNAME 0 |
robert_jw | 0:b2805b6888dc | 1080 | #endif |
robert_jw | 0:b2805b6888dc | 1081 | |
robert_jw | 0:b2805b6888dc | 1082 | /** |
robert_jw | 0:b2805b6888dc | 1083 | * LWIP_NETIF_API==1: Support netif api (in netifapi.c) |
robert_jw | 0:b2805b6888dc | 1084 | */ |
robert_jw | 0:b2805b6888dc | 1085 | #ifndef LWIP_NETIF_API |
robert_jw | 0:b2805b6888dc | 1086 | #define LWIP_NETIF_API 0 |
robert_jw | 0:b2805b6888dc | 1087 | #endif |
robert_jw | 0:b2805b6888dc | 1088 | |
robert_jw | 0:b2805b6888dc | 1089 | /** |
robert_jw | 0:b2805b6888dc | 1090 | * LWIP_NETIF_STATUS_CALLBACK==1: Support a callback function whenever an interface |
robert_jw | 0:b2805b6888dc | 1091 | * changes its up/down status (i.e., due to DHCP IP acquistion) |
robert_jw | 0:b2805b6888dc | 1092 | */ |
robert_jw | 0:b2805b6888dc | 1093 | #ifndef LWIP_NETIF_STATUS_CALLBACK |
robert_jw | 0:b2805b6888dc | 1094 | #define LWIP_NETIF_STATUS_CALLBACK 0 |
robert_jw | 0:b2805b6888dc | 1095 | #endif |
robert_jw | 0:b2805b6888dc | 1096 | |
robert_jw | 0:b2805b6888dc | 1097 | /** |
robert_jw | 0:b2805b6888dc | 1098 | * LWIP_NETIF_LINK_CALLBACK==1: Support a callback function from an interface |
robert_jw | 0:b2805b6888dc | 1099 | * whenever the link changes (i.e., link down) |
robert_jw | 0:b2805b6888dc | 1100 | */ |
robert_jw | 0:b2805b6888dc | 1101 | #ifndef LWIP_NETIF_LINK_CALLBACK |
robert_jw | 0:b2805b6888dc | 1102 | #define LWIP_NETIF_LINK_CALLBACK 0 |
robert_jw | 0:b2805b6888dc | 1103 | #endif |
robert_jw | 0:b2805b6888dc | 1104 | |
robert_jw | 0:b2805b6888dc | 1105 | /** |
robert_jw | 0:b2805b6888dc | 1106 | * LWIP_NETIF_HWADDRHINT==1: Cache link-layer-address hints (e.g. table |
robert_jw | 0:b2805b6888dc | 1107 | * indices) in struct netif. TCP and UDP can make use of this to prevent |
robert_jw | 0:b2805b6888dc | 1108 | * scanning the ARP table for every sent packet. While this is faster for big |
robert_jw | 0:b2805b6888dc | 1109 | * ARP tables or many concurrent connections, it might be counterproductive |
robert_jw | 0:b2805b6888dc | 1110 | * if you have a tiny ARP table or if there never are concurrent connections. |
robert_jw | 0:b2805b6888dc | 1111 | */ |
robert_jw | 0:b2805b6888dc | 1112 | #ifndef LWIP_NETIF_HWADDRHINT |
robert_jw | 0:b2805b6888dc | 1113 | #define LWIP_NETIF_HWADDRHINT 0 |
robert_jw | 0:b2805b6888dc | 1114 | #endif |
robert_jw | 0:b2805b6888dc | 1115 | |
robert_jw | 0:b2805b6888dc | 1116 | /** |
robert_jw | 0:b2805b6888dc | 1117 | * LWIP_NETIF_LOOPBACK==1: Support sending packets with a destination IP |
robert_jw | 0:b2805b6888dc | 1118 | * address equal to the netif IP address, looping them back up the stack. |
robert_jw | 0:b2805b6888dc | 1119 | */ |
robert_jw | 0:b2805b6888dc | 1120 | #ifndef LWIP_NETIF_LOOPBACK |
robert_jw | 0:b2805b6888dc | 1121 | #define LWIP_NETIF_LOOPBACK 0 |
robert_jw | 0:b2805b6888dc | 1122 | #endif |
robert_jw | 0:b2805b6888dc | 1123 | |
robert_jw | 0:b2805b6888dc | 1124 | /** |
robert_jw | 0:b2805b6888dc | 1125 | * LWIP_LOOPBACK_MAX_PBUFS: Maximum number of pbufs on queue for loopback |
robert_jw | 0:b2805b6888dc | 1126 | * sending for each netif (0 = disabled) |
robert_jw | 0:b2805b6888dc | 1127 | */ |
robert_jw | 0:b2805b6888dc | 1128 | #ifndef LWIP_LOOPBACK_MAX_PBUFS |
robert_jw | 0:b2805b6888dc | 1129 | #define LWIP_LOOPBACK_MAX_PBUFS 0 |
robert_jw | 0:b2805b6888dc | 1130 | #endif |
robert_jw | 0:b2805b6888dc | 1131 | |
robert_jw | 0:b2805b6888dc | 1132 | /** |
robert_jw | 0:b2805b6888dc | 1133 | * LWIP_NETIF_LOOPBACK_MULTITHREADING: Indicates whether threading is enabled in |
robert_jw | 0:b2805b6888dc | 1134 | * the system, as netifs must change how they behave depending on this setting |
robert_jw | 0:b2805b6888dc | 1135 | * for the LWIP_NETIF_LOOPBACK option to work. |
robert_jw | 0:b2805b6888dc | 1136 | * Setting this is needed to avoid reentering non-reentrant functions like |
robert_jw | 0:b2805b6888dc | 1137 | * tcp_input(). |
robert_jw | 0:b2805b6888dc | 1138 | * LWIP_NETIF_LOOPBACK_MULTITHREADING==1: Indicates that the user is using a |
robert_jw | 0:b2805b6888dc | 1139 | * multithreaded environment like tcpip.c. In this case, netif->input() |
robert_jw | 0:b2805b6888dc | 1140 | * is called directly. |
robert_jw | 0:b2805b6888dc | 1141 | * LWIP_NETIF_LOOPBACK_MULTITHREADING==0: Indicates a polling (or NO_SYS) setup. |
robert_jw | 0:b2805b6888dc | 1142 | * The packets are put on a list and netif_poll() must be called in |
robert_jw | 0:b2805b6888dc | 1143 | * the main application loop. |
robert_jw | 0:b2805b6888dc | 1144 | */ |
robert_jw | 0:b2805b6888dc | 1145 | #ifndef LWIP_NETIF_LOOPBACK_MULTITHREADING |
robert_jw | 0:b2805b6888dc | 1146 | #define LWIP_NETIF_LOOPBACK_MULTITHREADING (!NO_SYS) |
robert_jw | 0:b2805b6888dc | 1147 | #endif |
robert_jw | 0:b2805b6888dc | 1148 | |
robert_jw | 0:b2805b6888dc | 1149 | /** |
robert_jw | 0:b2805b6888dc | 1150 | * LWIP_NETIF_TX_SINGLE_PBUF: if this is set to 1, lwIP tries to put all data |
robert_jw | 0:b2805b6888dc | 1151 | * to be sent into one single pbuf. This is for compatibility with DMA-enabled |
robert_jw | 0:b2805b6888dc | 1152 | * MACs that do not support scatter-gather. |
robert_jw | 0:b2805b6888dc | 1153 | * Beware that this might involve CPU-memcpy before transmitting that would not |
robert_jw | 0:b2805b6888dc | 1154 | * be needed without this flag! Use this only if you need to! |
robert_jw | 0:b2805b6888dc | 1155 | * |
robert_jw | 0:b2805b6888dc | 1156 | * @todo: TCP and IP-frag do not work with this, yet: |
robert_jw | 0:b2805b6888dc | 1157 | */ |
robert_jw | 0:b2805b6888dc | 1158 | #ifndef LWIP_NETIF_TX_SINGLE_PBUF |
robert_jw | 0:b2805b6888dc | 1159 | #define LWIP_NETIF_TX_SINGLE_PBUF 0 |
robert_jw | 0:b2805b6888dc | 1160 | #endif /* LWIP_NETIF_TX_SINGLE_PBUF */ |
robert_jw | 0:b2805b6888dc | 1161 | |
robert_jw | 0:b2805b6888dc | 1162 | /* |
robert_jw | 0:b2805b6888dc | 1163 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 1164 | ---------- LOOPIF options ---------- |
robert_jw | 0:b2805b6888dc | 1165 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 1166 | */ |
robert_jw | 0:b2805b6888dc | 1167 | /** |
robert_jw | 0:b2805b6888dc | 1168 | * LWIP_HAVE_LOOPIF==1: Support loop interface (127.0.0.1) and loopif.c |
robert_jw | 0:b2805b6888dc | 1169 | */ |
robert_jw | 0:b2805b6888dc | 1170 | #ifndef LWIP_HAVE_LOOPIF |
robert_jw | 0:b2805b6888dc | 1171 | #define LWIP_HAVE_LOOPIF 0 |
robert_jw | 0:b2805b6888dc | 1172 | #endif |
robert_jw | 0:b2805b6888dc | 1173 | |
robert_jw | 0:b2805b6888dc | 1174 | /* |
robert_jw | 0:b2805b6888dc | 1175 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 1176 | ---------- SLIPIF options ---------- |
robert_jw | 0:b2805b6888dc | 1177 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 1178 | */ |
robert_jw | 0:b2805b6888dc | 1179 | /** |
robert_jw | 0:b2805b6888dc | 1180 | * LWIP_HAVE_SLIPIF==1: Support slip interface and slipif.c |
robert_jw | 0:b2805b6888dc | 1181 | */ |
robert_jw | 0:b2805b6888dc | 1182 | #ifndef LWIP_HAVE_SLIPIF |
robert_jw | 0:b2805b6888dc | 1183 | #define LWIP_HAVE_SLIPIF 0 |
robert_jw | 0:b2805b6888dc | 1184 | #endif |
robert_jw | 0:b2805b6888dc | 1185 | |
robert_jw | 0:b2805b6888dc | 1186 | /* |
robert_jw | 0:b2805b6888dc | 1187 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 1188 | ---------- Thread options ---------- |
robert_jw | 0:b2805b6888dc | 1189 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 1190 | */ |
robert_jw | 0:b2805b6888dc | 1191 | /** |
robert_jw | 0:b2805b6888dc | 1192 | * TCPIP_THREAD_NAME: The name assigned to the main tcpip thread. |
robert_jw | 0:b2805b6888dc | 1193 | */ |
robert_jw | 0:b2805b6888dc | 1194 | #ifndef TCPIP_THREAD_NAME |
robert_jw | 0:b2805b6888dc | 1195 | #define TCPIP_THREAD_NAME "tcpip_thread" |
robert_jw | 0:b2805b6888dc | 1196 | #endif |
robert_jw | 0:b2805b6888dc | 1197 | |
robert_jw | 0:b2805b6888dc | 1198 | /** |
robert_jw | 0:b2805b6888dc | 1199 | * TCPIP_THREAD_STACKSIZE: The stack size used by the main tcpip thread. |
robert_jw | 0:b2805b6888dc | 1200 | * The stack size value itself is platform-dependent, but is passed to |
robert_jw | 0:b2805b6888dc | 1201 | * sys_thread_new() when the thread is created. |
robert_jw | 0:b2805b6888dc | 1202 | */ |
robert_jw | 0:b2805b6888dc | 1203 | #ifndef TCPIP_THREAD_STACKSIZE |
robert_jw | 0:b2805b6888dc | 1204 | #define TCPIP_THREAD_STACKSIZE 0 |
robert_jw | 0:b2805b6888dc | 1205 | #endif |
robert_jw | 0:b2805b6888dc | 1206 | |
robert_jw | 0:b2805b6888dc | 1207 | /** |
robert_jw | 0:b2805b6888dc | 1208 | * TCPIP_THREAD_PRIO: The priority assigned to the main tcpip thread. |
robert_jw | 0:b2805b6888dc | 1209 | * The priority value itself is platform-dependent, but is passed to |
robert_jw | 0:b2805b6888dc | 1210 | * sys_thread_new() when the thread is created. |
robert_jw | 0:b2805b6888dc | 1211 | */ |
robert_jw | 0:b2805b6888dc | 1212 | #ifndef TCPIP_THREAD_PRIO |
robert_jw | 0:b2805b6888dc | 1213 | #define TCPIP_THREAD_PRIO 1 |
robert_jw | 0:b2805b6888dc | 1214 | #endif |
robert_jw | 0:b2805b6888dc | 1215 | |
robert_jw | 0:b2805b6888dc | 1216 | /** |
robert_jw | 0:b2805b6888dc | 1217 | * TCPIP_MBOX_SIZE: The mailbox size for the tcpip thread messages |
robert_jw | 0:b2805b6888dc | 1218 | * The queue size value itself is platform-dependent, but is passed to |
robert_jw | 0:b2805b6888dc | 1219 | * sys_mbox_new() when tcpip_init is called. |
robert_jw | 0:b2805b6888dc | 1220 | */ |
robert_jw | 0:b2805b6888dc | 1221 | #ifndef TCPIP_MBOX_SIZE |
robert_jw | 0:b2805b6888dc | 1222 | #define TCPIP_MBOX_SIZE 0 |
robert_jw | 0:b2805b6888dc | 1223 | #endif |
robert_jw | 0:b2805b6888dc | 1224 | |
robert_jw | 0:b2805b6888dc | 1225 | /** |
robert_jw | 0:b2805b6888dc | 1226 | * SLIPIF_THREAD_NAME: The name assigned to the slipif_loop thread. |
robert_jw | 0:b2805b6888dc | 1227 | */ |
robert_jw | 0:b2805b6888dc | 1228 | #ifndef SLIPIF_THREAD_NAME |
robert_jw | 0:b2805b6888dc | 1229 | #define SLIPIF_THREAD_NAME "slipif_loop" |
robert_jw | 0:b2805b6888dc | 1230 | #endif |
robert_jw | 0:b2805b6888dc | 1231 | |
robert_jw | 0:b2805b6888dc | 1232 | /** |
robert_jw | 0:b2805b6888dc | 1233 | * SLIP_THREAD_STACKSIZE: The stack size used by the slipif_loop thread. |
robert_jw | 0:b2805b6888dc | 1234 | * The stack size value itself is platform-dependent, but is passed to |
robert_jw | 0:b2805b6888dc | 1235 | * sys_thread_new() when the thread is created. |
robert_jw | 0:b2805b6888dc | 1236 | */ |
robert_jw | 0:b2805b6888dc | 1237 | #ifndef SLIPIF_THREAD_STACKSIZE |
robert_jw | 0:b2805b6888dc | 1238 | #define SLIPIF_THREAD_STACKSIZE 0 |
robert_jw | 0:b2805b6888dc | 1239 | #endif |
robert_jw | 0:b2805b6888dc | 1240 | |
robert_jw | 0:b2805b6888dc | 1241 | /** |
robert_jw | 0:b2805b6888dc | 1242 | * SLIPIF_THREAD_PRIO: The priority assigned to the slipif_loop thread. |
robert_jw | 0:b2805b6888dc | 1243 | * The priority value itself is platform-dependent, but is passed to |
robert_jw | 0:b2805b6888dc | 1244 | * sys_thread_new() when the thread is created. |
robert_jw | 0:b2805b6888dc | 1245 | */ |
robert_jw | 0:b2805b6888dc | 1246 | #ifndef SLIPIF_THREAD_PRIO |
robert_jw | 0:b2805b6888dc | 1247 | #define SLIPIF_THREAD_PRIO 1 |
robert_jw | 0:b2805b6888dc | 1248 | #endif |
robert_jw | 0:b2805b6888dc | 1249 | |
robert_jw | 0:b2805b6888dc | 1250 | /** |
robert_jw | 0:b2805b6888dc | 1251 | * PPP_THREAD_NAME: The name assigned to the pppInputThread. |
robert_jw | 0:b2805b6888dc | 1252 | */ |
robert_jw | 0:b2805b6888dc | 1253 | #ifndef PPP_THREAD_NAME |
robert_jw | 0:b2805b6888dc | 1254 | #define PPP_THREAD_NAME "pppInputThread" |
robert_jw | 0:b2805b6888dc | 1255 | #endif |
robert_jw | 0:b2805b6888dc | 1256 | |
robert_jw | 0:b2805b6888dc | 1257 | /** |
robert_jw | 0:b2805b6888dc | 1258 | * PPP_THREAD_STACKSIZE: The stack size used by the pppInputThread. |
robert_jw | 0:b2805b6888dc | 1259 | * The stack size value itself is platform-dependent, but is passed to |
robert_jw | 0:b2805b6888dc | 1260 | * sys_thread_new() when the thread is created. |
robert_jw | 0:b2805b6888dc | 1261 | */ |
robert_jw | 0:b2805b6888dc | 1262 | #ifndef PPP_THREAD_STACKSIZE |
robert_jw | 0:b2805b6888dc | 1263 | #define PPP_THREAD_STACKSIZE 0 |
robert_jw | 0:b2805b6888dc | 1264 | #endif |
robert_jw | 0:b2805b6888dc | 1265 | |
robert_jw | 0:b2805b6888dc | 1266 | /** |
robert_jw | 0:b2805b6888dc | 1267 | * PPP_THREAD_PRIO: The priority assigned to the pppInputThread. |
robert_jw | 0:b2805b6888dc | 1268 | * The priority value itself is platform-dependent, but is passed to |
robert_jw | 0:b2805b6888dc | 1269 | * sys_thread_new() when the thread is created. |
robert_jw | 0:b2805b6888dc | 1270 | */ |
robert_jw | 0:b2805b6888dc | 1271 | #ifndef PPP_THREAD_PRIO |
robert_jw | 0:b2805b6888dc | 1272 | #define PPP_THREAD_PRIO 1 |
robert_jw | 0:b2805b6888dc | 1273 | #endif |
robert_jw | 0:b2805b6888dc | 1274 | |
robert_jw | 0:b2805b6888dc | 1275 | /** |
robert_jw | 0:b2805b6888dc | 1276 | * DEFAULT_THREAD_NAME: The name assigned to any other lwIP thread. |
robert_jw | 0:b2805b6888dc | 1277 | */ |
robert_jw | 0:b2805b6888dc | 1278 | #ifndef DEFAULT_THREAD_NAME |
robert_jw | 0:b2805b6888dc | 1279 | #define DEFAULT_THREAD_NAME "lwIP" |
robert_jw | 0:b2805b6888dc | 1280 | #endif |
robert_jw | 0:b2805b6888dc | 1281 | |
robert_jw | 0:b2805b6888dc | 1282 | /** |
robert_jw | 0:b2805b6888dc | 1283 | * DEFAULT_THREAD_STACKSIZE: The stack size used by any other lwIP thread. |
robert_jw | 0:b2805b6888dc | 1284 | * The stack size value itself is platform-dependent, but is passed to |
robert_jw | 0:b2805b6888dc | 1285 | * sys_thread_new() when the thread is created. |
robert_jw | 0:b2805b6888dc | 1286 | */ |
robert_jw | 0:b2805b6888dc | 1287 | #ifndef DEFAULT_THREAD_STACKSIZE |
robert_jw | 0:b2805b6888dc | 1288 | #define DEFAULT_THREAD_STACKSIZE 0 |
robert_jw | 0:b2805b6888dc | 1289 | #endif |
robert_jw | 0:b2805b6888dc | 1290 | |
robert_jw | 0:b2805b6888dc | 1291 | /** |
robert_jw | 0:b2805b6888dc | 1292 | * DEFAULT_THREAD_PRIO: The priority assigned to any other lwIP thread. |
robert_jw | 0:b2805b6888dc | 1293 | * The priority value itself is platform-dependent, but is passed to |
robert_jw | 0:b2805b6888dc | 1294 | * sys_thread_new() when the thread is created. |
robert_jw | 0:b2805b6888dc | 1295 | */ |
robert_jw | 0:b2805b6888dc | 1296 | #ifndef DEFAULT_THREAD_PRIO |
robert_jw | 0:b2805b6888dc | 1297 | #define DEFAULT_THREAD_PRIO 1 |
robert_jw | 0:b2805b6888dc | 1298 | #endif |
robert_jw | 0:b2805b6888dc | 1299 | |
robert_jw | 0:b2805b6888dc | 1300 | /** |
robert_jw | 0:b2805b6888dc | 1301 | * DEFAULT_RAW_RECVMBOX_SIZE: The mailbox size for the incoming packets on a |
robert_jw | 0:b2805b6888dc | 1302 | * NETCONN_RAW. The queue size value itself is platform-dependent, but is passed |
robert_jw | 0:b2805b6888dc | 1303 | * to sys_mbox_new() when the recvmbox is created. |
robert_jw | 0:b2805b6888dc | 1304 | */ |
robert_jw | 0:b2805b6888dc | 1305 | #ifndef DEFAULT_RAW_RECVMBOX_SIZE |
robert_jw | 0:b2805b6888dc | 1306 | #define DEFAULT_RAW_RECVMBOX_SIZE 0 |
robert_jw | 0:b2805b6888dc | 1307 | #endif |
robert_jw | 0:b2805b6888dc | 1308 | |
robert_jw | 0:b2805b6888dc | 1309 | /** |
robert_jw | 0:b2805b6888dc | 1310 | * DEFAULT_UDP_RECVMBOX_SIZE: The mailbox size for the incoming packets on a |
robert_jw | 0:b2805b6888dc | 1311 | * NETCONN_UDP. The queue size value itself is platform-dependent, but is passed |
robert_jw | 0:b2805b6888dc | 1312 | * to sys_mbox_new() when the recvmbox is created. |
robert_jw | 0:b2805b6888dc | 1313 | */ |
robert_jw | 0:b2805b6888dc | 1314 | #ifndef DEFAULT_UDP_RECVMBOX_SIZE |
robert_jw | 0:b2805b6888dc | 1315 | #define DEFAULT_UDP_RECVMBOX_SIZE 0 |
robert_jw | 0:b2805b6888dc | 1316 | #endif |
robert_jw | 0:b2805b6888dc | 1317 | |
robert_jw | 0:b2805b6888dc | 1318 | /** |
robert_jw | 0:b2805b6888dc | 1319 | * DEFAULT_TCP_RECVMBOX_SIZE: The mailbox size for the incoming packets on a |
robert_jw | 0:b2805b6888dc | 1320 | * NETCONN_TCP. The queue size value itself is platform-dependent, but is passed |
robert_jw | 0:b2805b6888dc | 1321 | * to sys_mbox_new() when the recvmbox is created. |
robert_jw | 0:b2805b6888dc | 1322 | */ |
robert_jw | 0:b2805b6888dc | 1323 | #ifndef DEFAULT_TCP_RECVMBOX_SIZE |
robert_jw | 0:b2805b6888dc | 1324 | #define DEFAULT_TCP_RECVMBOX_SIZE 0 |
robert_jw | 0:b2805b6888dc | 1325 | #endif |
robert_jw | 0:b2805b6888dc | 1326 | |
robert_jw | 0:b2805b6888dc | 1327 | /** |
robert_jw | 0:b2805b6888dc | 1328 | * DEFAULT_ACCEPTMBOX_SIZE: The mailbox size for the incoming connections. |
robert_jw | 0:b2805b6888dc | 1329 | * The queue size value itself is platform-dependent, but is passed to |
robert_jw | 0:b2805b6888dc | 1330 | * sys_mbox_new() when the acceptmbox is created. |
robert_jw | 0:b2805b6888dc | 1331 | */ |
robert_jw | 0:b2805b6888dc | 1332 | #ifndef DEFAULT_ACCEPTMBOX_SIZE |
robert_jw | 0:b2805b6888dc | 1333 | #define DEFAULT_ACCEPTMBOX_SIZE 0 |
robert_jw | 0:b2805b6888dc | 1334 | #endif |
robert_jw | 0:b2805b6888dc | 1335 | |
robert_jw | 0:b2805b6888dc | 1336 | /* |
robert_jw | 0:b2805b6888dc | 1337 | ---------------------------------------------- |
robert_jw | 0:b2805b6888dc | 1338 | ---------- Sequential layer options ---------- |
robert_jw | 0:b2805b6888dc | 1339 | ---------------------------------------------- |
robert_jw | 0:b2805b6888dc | 1340 | */ |
robert_jw | 0:b2805b6888dc | 1341 | /** |
robert_jw | 0:b2805b6888dc | 1342 | * LWIP_TCPIP_CORE_LOCKING: (EXPERIMENTAL!) |
robert_jw | 0:b2805b6888dc | 1343 | * Don't use it if you're not an active lwIP project member |
robert_jw | 0:b2805b6888dc | 1344 | */ |
robert_jw | 0:b2805b6888dc | 1345 | #ifndef LWIP_TCPIP_CORE_LOCKING |
robert_jw | 0:b2805b6888dc | 1346 | #define LWIP_TCPIP_CORE_LOCKING 0 |
robert_jw | 0:b2805b6888dc | 1347 | #endif |
robert_jw | 0:b2805b6888dc | 1348 | |
robert_jw | 0:b2805b6888dc | 1349 | /** |
robert_jw | 0:b2805b6888dc | 1350 | * LWIP_TCPIP_CORE_LOCKING_INPUT: (EXPERIMENTAL!) |
robert_jw | 0:b2805b6888dc | 1351 | * Don't use it if you're not an active lwIP project member |
robert_jw | 0:b2805b6888dc | 1352 | */ |
robert_jw | 0:b2805b6888dc | 1353 | #ifndef LWIP_TCPIP_CORE_LOCKING_INPUT |
robert_jw | 0:b2805b6888dc | 1354 | #define LWIP_TCPIP_CORE_LOCKING_INPUT 0 |
robert_jw | 0:b2805b6888dc | 1355 | #endif |
robert_jw | 0:b2805b6888dc | 1356 | |
robert_jw | 0:b2805b6888dc | 1357 | /** |
robert_jw | 0:b2805b6888dc | 1358 | * LWIP_NETCONN==1: Enable Netconn API (require to use api_lib.c) |
robert_jw | 0:b2805b6888dc | 1359 | */ |
robert_jw | 0:b2805b6888dc | 1360 | #ifndef LWIP_NETCONN |
robert_jw | 0:b2805b6888dc | 1361 | #define LWIP_NETCONN 1 |
robert_jw | 0:b2805b6888dc | 1362 | #endif |
robert_jw | 0:b2805b6888dc | 1363 | |
robert_jw | 0:b2805b6888dc | 1364 | /** LWIP_TCPIP_TIMEOUT==1: Enable tcpip_timeout/tcpip_untimeout tod create |
robert_jw | 0:b2805b6888dc | 1365 | * timers running in tcpip_thread from another thread. |
robert_jw | 0:b2805b6888dc | 1366 | */ |
robert_jw | 0:b2805b6888dc | 1367 | #ifndef LWIP_TCPIP_TIMEOUT |
robert_jw | 0:b2805b6888dc | 1368 | #define LWIP_TCPIP_TIMEOUT 1 |
robert_jw | 0:b2805b6888dc | 1369 | #endif |
robert_jw | 0:b2805b6888dc | 1370 | |
robert_jw | 0:b2805b6888dc | 1371 | /* |
robert_jw | 0:b2805b6888dc | 1372 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 1373 | ---------- Socket options ---------- |
robert_jw | 0:b2805b6888dc | 1374 | ------------------------------------ |
robert_jw | 0:b2805b6888dc | 1375 | */ |
robert_jw | 0:b2805b6888dc | 1376 | /** |
robert_jw | 0:b2805b6888dc | 1377 | * LWIP_SOCKET==1: Enable Socket API (require to use sockets.c) |
robert_jw | 0:b2805b6888dc | 1378 | */ |
robert_jw | 0:b2805b6888dc | 1379 | #ifndef LWIP_SOCKET |
robert_jw | 0:b2805b6888dc | 1380 | #define LWIP_SOCKET 1 |
robert_jw | 0:b2805b6888dc | 1381 | #endif |
robert_jw | 0:b2805b6888dc | 1382 | |
robert_jw | 0:b2805b6888dc | 1383 | /** |
robert_jw | 0:b2805b6888dc | 1384 | * LWIP_COMPAT_SOCKETS==1: Enable BSD-style sockets functions names. |
robert_jw | 0:b2805b6888dc | 1385 | * (only used if you use sockets.c) |
robert_jw | 0:b2805b6888dc | 1386 | */ |
robert_jw | 0:b2805b6888dc | 1387 | #ifndef LWIP_COMPAT_SOCKETS |
robert_jw | 0:b2805b6888dc | 1388 | #define LWIP_COMPAT_SOCKETS 1 |
robert_jw | 0:b2805b6888dc | 1389 | #endif |
robert_jw | 0:b2805b6888dc | 1390 | |
robert_jw | 0:b2805b6888dc | 1391 | /** |
robert_jw | 0:b2805b6888dc | 1392 | * LWIP_POSIX_SOCKETS_IO_NAMES==1: Enable POSIX-style sockets functions names. |
robert_jw | 0:b2805b6888dc | 1393 | * Disable this option if you use a POSIX operating system that uses the same |
robert_jw | 0:b2805b6888dc | 1394 | * names (read, write & close). (only used if you use sockets.c) |
robert_jw | 0:b2805b6888dc | 1395 | */ |
robert_jw | 0:b2805b6888dc | 1396 | #ifndef LWIP_POSIX_SOCKETS_IO_NAMES |
robert_jw | 0:b2805b6888dc | 1397 | #define LWIP_POSIX_SOCKETS_IO_NAMES 1 |
robert_jw | 0:b2805b6888dc | 1398 | #endif |
robert_jw | 0:b2805b6888dc | 1399 | |
robert_jw | 0:b2805b6888dc | 1400 | /** |
robert_jw | 0:b2805b6888dc | 1401 | * LWIP_TCP_KEEPALIVE==1: Enable TCP_KEEPIDLE, TCP_KEEPINTVL and TCP_KEEPCNT |
robert_jw | 0:b2805b6888dc | 1402 | * options processing. Note that TCP_KEEPIDLE and TCP_KEEPINTVL have to be set |
robert_jw | 0:b2805b6888dc | 1403 | * in seconds. (does not require sockets.c, and will affect tcp.c) |
robert_jw | 0:b2805b6888dc | 1404 | */ |
robert_jw | 0:b2805b6888dc | 1405 | #ifndef LWIP_TCP_KEEPALIVE |
robert_jw | 0:b2805b6888dc | 1406 | #define LWIP_TCP_KEEPALIVE 0 |
robert_jw | 0:b2805b6888dc | 1407 | #endif |
robert_jw | 0:b2805b6888dc | 1408 | |
robert_jw | 0:b2805b6888dc | 1409 | /** |
robert_jw | 0:b2805b6888dc | 1410 | * LWIP_SO_RCVTIMEO==1: Enable SO_RCVTIMEO processing. |
robert_jw | 0:b2805b6888dc | 1411 | */ |
robert_jw | 0:b2805b6888dc | 1412 | #ifndef LWIP_SO_RCVTIMEO |
robert_jw | 0:b2805b6888dc | 1413 | #define LWIP_SO_RCVTIMEO 0 |
robert_jw | 0:b2805b6888dc | 1414 | #endif |
robert_jw | 0:b2805b6888dc | 1415 | |
robert_jw | 0:b2805b6888dc | 1416 | /** |
robert_jw | 0:b2805b6888dc | 1417 | * LWIP_SO_RCVBUF==1: Enable SO_RCVBUF processing. |
robert_jw | 0:b2805b6888dc | 1418 | */ |
robert_jw | 0:b2805b6888dc | 1419 | #ifndef LWIP_SO_RCVBUF |
robert_jw | 0:b2805b6888dc | 1420 | #define LWIP_SO_RCVBUF 0 |
robert_jw | 0:b2805b6888dc | 1421 | #endif |
robert_jw | 0:b2805b6888dc | 1422 | |
robert_jw | 0:b2805b6888dc | 1423 | /** |
robert_jw | 0:b2805b6888dc | 1424 | * If LWIP_SO_RCVBUF is used, this is the default value for recv_bufsize. |
robert_jw | 0:b2805b6888dc | 1425 | */ |
robert_jw | 0:b2805b6888dc | 1426 | #ifndef RECV_BUFSIZE_DEFAULT |
robert_jw | 0:b2805b6888dc | 1427 | #define RECV_BUFSIZE_DEFAULT INT_MAX |
robert_jw | 0:b2805b6888dc | 1428 | #endif |
robert_jw | 0:b2805b6888dc | 1429 | |
robert_jw | 0:b2805b6888dc | 1430 | /** |
robert_jw | 0:b2805b6888dc | 1431 | * SO_REUSE==1: Enable SO_REUSEADDR option. |
robert_jw | 0:b2805b6888dc | 1432 | */ |
robert_jw | 0:b2805b6888dc | 1433 | #ifndef SO_REUSE |
robert_jw | 0:b2805b6888dc | 1434 | #define SO_REUSE 0 |
robert_jw | 0:b2805b6888dc | 1435 | #endif |
robert_jw | 0:b2805b6888dc | 1436 | |
robert_jw | 0:b2805b6888dc | 1437 | /** |
robert_jw | 0:b2805b6888dc | 1438 | * SO_REUSE_RXTOALL==1: Pass a copy of incoming broadcast/multicast packets |
robert_jw | 0:b2805b6888dc | 1439 | * to all local matches if SO_REUSEADDR is turned on. |
robert_jw | 0:b2805b6888dc | 1440 | * WARNING: Adds a memcpy for every packet if passing to more than one pcb! |
robert_jw | 0:b2805b6888dc | 1441 | */ |
robert_jw | 0:b2805b6888dc | 1442 | #ifndef SO_REUSE_RXTOALL |
robert_jw | 0:b2805b6888dc | 1443 | #define SO_REUSE_RXTOALL 0 |
robert_jw | 0:b2805b6888dc | 1444 | #endif |
robert_jw | 0:b2805b6888dc | 1445 | |
robert_jw | 0:b2805b6888dc | 1446 | /* |
robert_jw | 0:b2805b6888dc | 1447 | ---------------------------------------- |
robert_jw | 0:b2805b6888dc | 1448 | ---------- Statistics options ---------- |
robert_jw | 0:b2805b6888dc | 1449 | ---------------------------------------- |
robert_jw | 0:b2805b6888dc | 1450 | */ |
robert_jw | 0:b2805b6888dc | 1451 | /** |
robert_jw | 0:b2805b6888dc | 1452 | * LWIP_STATS==1: Enable statistics collection in lwip_stats. |
robert_jw | 0:b2805b6888dc | 1453 | */ |
robert_jw | 0:b2805b6888dc | 1454 | #ifndef LWIP_STATS |
robert_jw | 0:b2805b6888dc | 1455 | #define LWIP_STATS 1 |
robert_jw | 0:b2805b6888dc | 1456 | #endif |
robert_jw | 0:b2805b6888dc | 1457 | |
robert_jw | 0:b2805b6888dc | 1458 | #if LWIP_STATS |
robert_jw | 0:b2805b6888dc | 1459 | |
robert_jw | 0:b2805b6888dc | 1460 | /** |
robert_jw | 0:b2805b6888dc | 1461 | * LWIP_STATS_DISPLAY==1: Compile in the statistics output functions. |
robert_jw | 0:b2805b6888dc | 1462 | */ |
robert_jw | 0:b2805b6888dc | 1463 | #ifndef LWIP_STATS_DISPLAY |
robert_jw | 0:b2805b6888dc | 1464 | #define LWIP_STATS_DISPLAY 0 |
robert_jw | 0:b2805b6888dc | 1465 | #endif |
robert_jw | 0:b2805b6888dc | 1466 | |
robert_jw | 0:b2805b6888dc | 1467 | /** |
robert_jw | 0:b2805b6888dc | 1468 | * LINK_STATS==1: Enable link stats. |
robert_jw | 0:b2805b6888dc | 1469 | */ |
robert_jw | 0:b2805b6888dc | 1470 | #ifndef LINK_STATS |
robert_jw | 0:b2805b6888dc | 1471 | #define LINK_STATS 1 |
robert_jw | 0:b2805b6888dc | 1472 | #endif |
robert_jw | 0:b2805b6888dc | 1473 | |
robert_jw | 0:b2805b6888dc | 1474 | /** |
robert_jw | 0:b2805b6888dc | 1475 | * ETHARP_STATS==1: Enable etharp stats. |
robert_jw | 0:b2805b6888dc | 1476 | */ |
robert_jw | 0:b2805b6888dc | 1477 | #ifndef ETHARP_STATS |
robert_jw | 0:b2805b6888dc | 1478 | #define ETHARP_STATS (LWIP_ARP) |
robert_jw | 0:b2805b6888dc | 1479 | #endif |
robert_jw | 0:b2805b6888dc | 1480 | |
robert_jw | 0:b2805b6888dc | 1481 | /** |
robert_jw | 0:b2805b6888dc | 1482 | * IP_STATS==1: Enable IP stats. |
robert_jw | 0:b2805b6888dc | 1483 | */ |
robert_jw | 0:b2805b6888dc | 1484 | #ifndef IP_STATS |
robert_jw | 0:b2805b6888dc | 1485 | #define IP_STATS 1 |
robert_jw | 0:b2805b6888dc | 1486 | #endif |
robert_jw | 0:b2805b6888dc | 1487 | |
robert_jw | 0:b2805b6888dc | 1488 | /** |
robert_jw | 0:b2805b6888dc | 1489 | * IPFRAG_STATS==1: Enable IP fragmentation stats. Default is |
robert_jw | 0:b2805b6888dc | 1490 | * on if using either frag or reass. |
robert_jw | 0:b2805b6888dc | 1491 | */ |
robert_jw | 0:b2805b6888dc | 1492 | #ifndef IPFRAG_STATS |
robert_jw | 0:b2805b6888dc | 1493 | #define IPFRAG_STATS (IP_REASSEMBLY || IP_FRAG) |
robert_jw | 0:b2805b6888dc | 1494 | #endif |
robert_jw | 0:b2805b6888dc | 1495 | |
robert_jw | 0:b2805b6888dc | 1496 | /** |
robert_jw | 0:b2805b6888dc | 1497 | * ICMP_STATS==1: Enable ICMP stats. |
robert_jw | 0:b2805b6888dc | 1498 | */ |
robert_jw | 0:b2805b6888dc | 1499 | #ifndef ICMP_STATS |
robert_jw | 0:b2805b6888dc | 1500 | #define ICMP_STATS 1 |
robert_jw | 0:b2805b6888dc | 1501 | #endif |
robert_jw | 0:b2805b6888dc | 1502 | |
robert_jw | 0:b2805b6888dc | 1503 | /** |
robert_jw | 0:b2805b6888dc | 1504 | * IGMP_STATS==1: Enable IGMP stats. |
robert_jw | 0:b2805b6888dc | 1505 | */ |
robert_jw | 0:b2805b6888dc | 1506 | #ifndef IGMP_STATS |
robert_jw | 0:b2805b6888dc | 1507 | #define IGMP_STATS (LWIP_IGMP) |
robert_jw | 0:b2805b6888dc | 1508 | #endif |
robert_jw | 0:b2805b6888dc | 1509 | |
robert_jw | 0:b2805b6888dc | 1510 | /** |
robert_jw | 0:b2805b6888dc | 1511 | * UDP_STATS==1: Enable UDP stats. Default is on if |
robert_jw | 0:b2805b6888dc | 1512 | * UDP enabled, otherwise off. |
robert_jw | 0:b2805b6888dc | 1513 | */ |
robert_jw | 0:b2805b6888dc | 1514 | #ifndef UDP_STATS |
robert_jw | 0:b2805b6888dc | 1515 | #define UDP_STATS (LWIP_UDP) |
robert_jw | 0:b2805b6888dc | 1516 | #endif |
robert_jw | 0:b2805b6888dc | 1517 | |
robert_jw | 0:b2805b6888dc | 1518 | /** |
robert_jw | 0:b2805b6888dc | 1519 | * TCP_STATS==1: Enable TCP stats. Default is on if TCP |
robert_jw | 0:b2805b6888dc | 1520 | * enabled, otherwise off. |
robert_jw | 0:b2805b6888dc | 1521 | */ |
robert_jw | 0:b2805b6888dc | 1522 | #ifndef TCP_STATS |
robert_jw | 0:b2805b6888dc | 1523 | #define TCP_STATS (LWIP_TCP) |
robert_jw | 0:b2805b6888dc | 1524 | #endif |
robert_jw | 0:b2805b6888dc | 1525 | |
robert_jw | 0:b2805b6888dc | 1526 | /** |
robert_jw | 0:b2805b6888dc | 1527 | * MEM_STATS==1: Enable mem.c stats. |
robert_jw | 0:b2805b6888dc | 1528 | */ |
robert_jw | 0:b2805b6888dc | 1529 | #ifndef MEM_STATS |
robert_jw | 0:b2805b6888dc | 1530 | #define MEM_STATS ((MEM_LIBC_MALLOC == 0) && (MEM_USE_POOLS == 0)) |
robert_jw | 0:b2805b6888dc | 1531 | #endif |
robert_jw | 0:b2805b6888dc | 1532 | |
robert_jw | 0:b2805b6888dc | 1533 | /** |
robert_jw | 0:b2805b6888dc | 1534 | * MEMP_STATS==1: Enable memp.c pool stats. |
robert_jw | 0:b2805b6888dc | 1535 | */ |
robert_jw | 0:b2805b6888dc | 1536 | #ifndef MEMP_STATS |
robert_jw | 0:b2805b6888dc | 1537 | #define MEMP_STATS (MEMP_MEM_MALLOC == 0) |
robert_jw | 0:b2805b6888dc | 1538 | #endif |
robert_jw | 0:b2805b6888dc | 1539 | |
robert_jw | 0:b2805b6888dc | 1540 | /** |
robert_jw | 0:b2805b6888dc | 1541 | * SYS_STATS==1: Enable system stats (sem and mbox counts, etc). |
robert_jw | 0:b2805b6888dc | 1542 | */ |
robert_jw | 0:b2805b6888dc | 1543 | #ifndef SYS_STATS |
robert_jw | 0:b2805b6888dc | 1544 | #define SYS_STATS (NO_SYS == 0) |
robert_jw | 0:b2805b6888dc | 1545 | #endif |
robert_jw | 0:b2805b6888dc | 1546 | |
robert_jw | 0:b2805b6888dc | 1547 | #else |
robert_jw | 0:b2805b6888dc | 1548 | |
robert_jw | 0:b2805b6888dc | 1549 | #define LINK_STATS 0 |
robert_jw | 0:b2805b6888dc | 1550 | #define IP_STATS 0 |
robert_jw | 0:b2805b6888dc | 1551 | #define IPFRAG_STATS 0 |
robert_jw | 0:b2805b6888dc | 1552 | #define ICMP_STATS 0 |
robert_jw | 0:b2805b6888dc | 1553 | #define IGMP_STATS 0 |
robert_jw | 0:b2805b6888dc | 1554 | #define UDP_STATS 0 |
robert_jw | 0:b2805b6888dc | 1555 | #define TCP_STATS 0 |
robert_jw | 0:b2805b6888dc | 1556 | #define MEM_STATS 0 |
robert_jw | 0:b2805b6888dc | 1557 | #define MEMP_STATS 0 |
robert_jw | 0:b2805b6888dc | 1558 | #define SYS_STATS 0 |
robert_jw | 0:b2805b6888dc | 1559 | #define LWIP_STATS_DISPLAY 0 |
robert_jw | 0:b2805b6888dc | 1560 | |
robert_jw | 0:b2805b6888dc | 1561 | #endif /* LWIP_STATS */ |
robert_jw | 0:b2805b6888dc | 1562 | |
robert_jw | 0:b2805b6888dc | 1563 | /* |
robert_jw | 0:b2805b6888dc | 1564 | --------------------------------- |
robert_jw | 0:b2805b6888dc | 1565 | ---------- PPP options ---------- |
robert_jw | 0:b2805b6888dc | 1566 | --------------------------------- |
robert_jw | 0:b2805b6888dc | 1567 | */ |
robert_jw | 0:b2805b6888dc | 1568 | /** |
robert_jw | 0:b2805b6888dc | 1569 | * PPP_SUPPORT==1: Enable PPP. |
robert_jw | 0:b2805b6888dc | 1570 | */ |
robert_jw | 0:b2805b6888dc | 1571 | #ifndef PPP_SUPPORT |
robert_jw | 0:b2805b6888dc | 1572 | #define PPP_SUPPORT 0 |
robert_jw | 0:b2805b6888dc | 1573 | #endif |
robert_jw | 0:b2805b6888dc | 1574 | |
robert_jw | 0:b2805b6888dc | 1575 | /** |
robert_jw | 0:b2805b6888dc | 1576 | * PPPOE_SUPPORT==1: Enable PPP Over Ethernet |
robert_jw | 0:b2805b6888dc | 1577 | */ |
robert_jw | 0:b2805b6888dc | 1578 | #ifndef PPPOE_SUPPORT |
robert_jw | 0:b2805b6888dc | 1579 | #define PPPOE_SUPPORT 0 |
robert_jw | 0:b2805b6888dc | 1580 | #endif |
robert_jw | 0:b2805b6888dc | 1581 | |
robert_jw | 0:b2805b6888dc | 1582 | /** |
robert_jw | 0:b2805b6888dc | 1583 | * PPPOS_SUPPORT==1: Enable PPP Over Serial |
robert_jw | 0:b2805b6888dc | 1584 | */ |
robert_jw | 0:b2805b6888dc | 1585 | #ifndef PPPOS_SUPPORT |
robert_jw | 0:b2805b6888dc | 1586 | #define PPPOS_SUPPORT PPP_SUPPORT |
robert_jw | 0:b2805b6888dc | 1587 | #endif |
robert_jw | 0:b2805b6888dc | 1588 | |
robert_jw | 0:b2805b6888dc | 1589 | #if PPP_SUPPORT |
robert_jw | 0:b2805b6888dc | 1590 | |
robert_jw | 0:b2805b6888dc | 1591 | /** |
robert_jw | 0:b2805b6888dc | 1592 | * NUM_PPP: Max PPP sessions. |
robert_jw | 0:b2805b6888dc | 1593 | */ |
robert_jw | 0:b2805b6888dc | 1594 | #ifndef NUM_PPP |
robert_jw | 0:b2805b6888dc | 1595 | #define NUM_PPP 1 |
robert_jw | 0:b2805b6888dc | 1596 | #endif |
robert_jw | 0:b2805b6888dc | 1597 | |
robert_jw | 0:b2805b6888dc | 1598 | /** |
robert_jw | 0:b2805b6888dc | 1599 | * PAP_SUPPORT==1: Support PAP. |
robert_jw | 0:b2805b6888dc | 1600 | */ |
robert_jw | 0:b2805b6888dc | 1601 | #ifndef PAP_SUPPORT |
robert_jw | 0:b2805b6888dc | 1602 | #define PAP_SUPPORT 0 |
robert_jw | 0:b2805b6888dc | 1603 | #endif |
robert_jw | 0:b2805b6888dc | 1604 | |
robert_jw | 0:b2805b6888dc | 1605 | /** |
robert_jw | 0:b2805b6888dc | 1606 | * CHAP_SUPPORT==1: Support CHAP. |
robert_jw | 0:b2805b6888dc | 1607 | */ |
robert_jw | 0:b2805b6888dc | 1608 | #ifndef CHAP_SUPPORT |
robert_jw | 0:b2805b6888dc | 1609 | #define CHAP_SUPPORT 0 |
robert_jw | 0:b2805b6888dc | 1610 | #endif |
robert_jw | 0:b2805b6888dc | 1611 | |
robert_jw | 0:b2805b6888dc | 1612 | /** |
robert_jw | 0:b2805b6888dc | 1613 | * MSCHAP_SUPPORT==1: Support MSCHAP. CURRENTLY NOT SUPPORTED! DO NOT SET! |
robert_jw | 0:b2805b6888dc | 1614 | */ |
robert_jw | 0:b2805b6888dc | 1615 | #ifndef MSCHAP_SUPPORT |
robert_jw | 0:b2805b6888dc | 1616 | #define MSCHAP_SUPPORT 0 |
robert_jw | 0:b2805b6888dc | 1617 | #endif |
robert_jw | 0:b2805b6888dc | 1618 | |
robert_jw | 0:b2805b6888dc | 1619 | /** |
robert_jw | 0:b2805b6888dc | 1620 | * CBCP_SUPPORT==1: Support CBCP. CURRENTLY NOT SUPPORTED! DO NOT SET! |
robert_jw | 0:b2805b6888dc | 1621 | */ |
robert_jw | 0:b2805b6888dc | 1622 | #ifndef CBCP_SUPPORT |
robert_jw | 0:b2805b6888dc | 1623 | #define CBCP_SUPPORT 0 |
robert_jw | 0:b2805b6888dc | 1624 | #endif |
robert_jw | 0:b2805b6888dc | 1625 | |
robert_jw | 0:b2805b6888dc | 1626 | /** |
robert_jw | 0:b2805b6888dc | 1627 | * CCP_SUPPORT==1: Support CCP. CURRENTLY NOT SUPPORTED! DO NOT SET! |
robert_jw | 0:b2805b6888dc | 1628 | */ |
robert_jw | 0:b2805b6888dc | 1629 | #ifndef CCP_SUPPORT |
robert_jw | 0:b2805b6888dc | 1630 | #define CCP_SUPPORT 0 |
robert_jw | 0:b2805b6888dc | 1631 | #endif |
robert_jw | 0:b2805b6888dc | 1632 | |
robert_jw | 0:b2805b6888dc | 1633 | /** |
robert_jw | 0:b2805b6888dc | 1634 | * VJ_SUPPORT==1: Support VJ header compression. |
robert_jw | 0:b2805b6888dc | 1635 | */ |
robert_jw | 0:b2805b6888dc | 1636 | #ifndef VJ_SUPPORT |
robert_jw | 0:b2805b6888dc | 1637 | #define VJ_SUPPORT 0 |
robert_jw | 0:b2805b6888dc | 1638 | #endif |
robert_jw | 0:b2805b6888dc | 1639 | |
robert_jw | 0:b2805b6888dc | 1640 | /** |
robert_jw | 0:b2805b6888dc | 1641 | * MD5_SUPPORT==1: Support MD5 (see also CHAP). |
robert_jw | 0:b2805b6888dc | 1642 | */ |
robert_jw | 0:b2805b6888dc | 1643 | #ifndef MD5_SUPPORT |
robert_jw | 0:b2805b6888dc | 1644 | #define MD5_SUPPORT 0 |
robert_jw | 0:b2805b6888dc | 1645 | #endif |
robert_jw | 0:b2805b6888dc | 1646 | |
robert_jw | 0:b2805b6888dc | 1647 | /* |
robert_jw | 0:b2805b6888dc | 1648 | * Timeouts |
robert_jw | 0:b2805b6888dc | 1649 | */ |
robert_jw | 0:b2805b6888dc | 1650 | #ifndef FSM_DEFTIMEOUT |
robert_jw | 0:b2805b6888dc | 1651 | #define FSM_DEFTIMEOUT 6 /* Timeout time in seconds */ |
robert_jw | 0:b2805b6888dc | 1652 | #endif |
robert_jw | 0:b2805b6888dc | 1653 | |
robert_jw | 0:b2805b6888dc | 1654 | #ifndef FSM_DEFMAXTERMREQS |
robert_jw | 0:b2805b6888dc | 1655 | #define FSM_DEFMAXTERMREQS 2 /* Maximum Terminate-Request transmissions */ |
robert_jw | 0:b2805b6888dc | 1656 | #endif |
robert_jw | 0:b2805b6888dc | 1657 | |
robert_jw | 0:b2805b6888dc | 1658 | #ifndef FSM_DEFMAXCONFREQS |
robert_jw | 0:b2805b6888dc | 1659 | #define FSM_DEFMAXCONFREQS 10 /* Maximum Configure-Request transmissions */ |
robert_jw | 0:b2805b6888dc | 1660 | #endif |
robert_jw | 0:b2805b6888dc | 1661 | |
robert_jw | 0:b2805b6888dc | 1662 | #ifndef FSM_DEFMAXNAKLOOPS |
robert_jw | 0:b2805b6888dc | 1663 | #define FSM_DEFMAXNAKLOOPS 5 /* Maximum number of nak loops */ |
robert_jw | 0:b2805b6888dc | 1664 | #endif |
robert_jw | 0:b2805b6888dc | 1665 | |
robert_jw | 0:b2805b6888dc | 1666 | #ifndef UPAP_DEFTIMEOUT |
robert_jw | 0:b2805b6888dc | 1667 | #define UPAP_DEFTIMEOUT 6 /* Timeout (seconds) for retransmitting req */ |
robert_jw | 0:b2805b6888dc | 1668 | #endif |
robert_jw | 0:b2805b6888dc | 1669 | |
robert_jw | 0:b2805b6888dc | 1670 | #ifndef UPAP_DEFREQTIME |
robert_jw | 0:b2805b6888dc | 1671 | #define UPAP_DEFREQTIME 30 /* Time to wait for auth-req from peer */ |
robert_jw | 0:b2805b6888dc | 1672 | #endif |
robert_jw | 0:b2805b6888dc | 1673 | |
robert_jw | 0:b2805b6888dc | 1674 | #ifndef CHAP_DEFTIMEOUT |
robert_jw | 0:b2805b6888dc | 1675 | #define CHAP_DEFTIMEOUT 6 /* Timeout time in seconds */ |
robert_jw | 0:b2805b6888dc | 1676 | #endif |
robert_jw | 0:b2805b6888dc | 1677 | |
robert_jw | 0:b2805b6888dc | 1678 | #ifndef CHAP_DEFTRANSMITS |
robert_jw | 0:b2805b6888dc | 1679 | #define CHAP_DEFTRANSMITS 10 /* max # times to send challenge */ |
robert_jw | 0:b2805b6888dc | 1680 | #endif |
robert_jw | 0:b2805b6888dc | 1681 | |
robert_jw | 0:b2805b6888dc | 1682 | /* Interval in seconds between keepalive echo requests, 0 to disable. */ |
robert_jw | 0:b2805b6888dc | 1683 | #ifndef LCP_ECHOINTERVAL |
robert_jw | 0:b2805b6888dc | 1684 | #define LCP_ECHOINTERVAL 0 |
robert_jw | 0:b2805b6888dc | 1685 | #endif |
robert_jw | 0:b2805b6888dc | 1686 | |
robert_jw | 0:b2805b6888dc | 1687 | /* Number of unanswered echo requests before failure. */ |
robert_jw | 0:b2805b6888dc | 1688 | #ifndef LCP_MAXECHOFAILS |
robert_jw | 0:b2805b6888dc | 1689 | #define LCP_MAXECHOFAILS 3 |
robert_jw | 0:b2805b6888dc | 1690 | #endif |
robert_jw | 0:b2805b6888dc | 1691 | |
robert_jw | 0:b2805b6888dc | 1692 | /* Max Xmit idle time (in jiffies) before resend flag char. */ |
robert_jw | 0:b2805b6888dc | 1693 | #ifndef PPP_MAXIDLEFLAG |
robert_jw | 0:b2805b6888dc | 1694 | #define PPP_MAXIDLEFLAG 100 |
robert_jw | 0:b2805b6888dc | 1695 | #endif |
robert_jw | 0:b2805b6888dc | 1696 | |
robert_jw | 0:b2805b6888dc | 1697 | /* |
robert_jw | 0:b2805b6888dc | 1698 | * Packet sizes |
robert_jw | 0:b2805b6888dc | 1699 | * |
robert_jw | 0:b2805b6888dc | 1700 | * Note - lcp shouldn't be allowed to negotiate stuff outside these |
robert_jw | 0:b2805b6888dc | 1701 | * limits. See lcp.h in the pppd directory. |
robert_jw | 0:b2805b6888dc | 1702 | * (XXX - these constants should simply be shared by lcp.c instead |
robert_jw | 0:b2805b6888dc | 1703 | * of living in lcp.h) |
robert_jw | 0:b2805b6888dc | 1704 | */ |
robert_jw | 0:b2805b6888dc | 1705 | #define PPP_MTU 1500 /* Default MTU (size of Info field) */ |
robert_jw | 0:b2805b6888dc | 1706 | #ifndef PPP_MAXMTU |
robert_jw | 0:b2805b6888dc | 1707 | /* #define PPP_MAXMTU 65535 - (PPP_HDRLEN + PPP_FCSLEN) */ |
robert_jw | 0:b2805b6888dc | 1708 | #define PPP_MAXMTU 1500 /* Largest MTU we allow */ |
robert_jw | 0:b2805b6888dc | 1709 | #endif |
robert_jw | 0:b2805b6888dc | 1710 | #define PPP_MINMTU 64 |
robert_jw | 0:b2805b6888dc | 1711 | #define PPP_MRU 1500 /* default MRU = max length of info field */ |
robert_jw | 0:b2805b6888dc | 1712 | #define PPP_MAXMRU 1500 /* Largest MRU we allow */ |
robert_jw | 0:b2805b6888dc | 1713 | #ifndef PPP_DEFMRU |
robert_jw | 0:b2805b6888dc | 1714 | #define PPP_DEFMRU 296 /* Try for this */ |
robert_jw | 0:b2805b6888dc | 1715 | #endif |
robert_jw | 0:b2805b6888dc | 1716 | #define PPP_MINMRU 128 /* No MRUs below this */ |
robert_jw | 0:b2805b6888dc | 1717 | |
robert_jw | 0:b2805b6888dc | 1718 | #ifndef MAXNAMELEN |
robert_jw | 0:b2805b6888dc | 1719 | #define MAXNAMELEN 256 /* max length of hostname or name for auth */ |
robert_jw | 0:b2805b6888dc | 1720 | #endif |
robert_jw | 0:b2805b6888dc | 1721 | #ifndef MAXSECRETLEN |
robert_jw | 0:b2805b6888dc | 1722 | #define MAXSECRETLEN 256 /* max length of password or secret */ |
robert_jw | 0:b2805b6888dc | 1723 | #endif |
robert_jw | 0:b2805b6888dc | 1724 | |
robert_jw | 0:b2805b6888dc | 1725 | #endif /* PPP_SUPPORT */ |
robert_jw | 0:b2805b6888dc | 1726 | |
robert_jw | 0:b2805b6888dc | 1727 | /* |
robert_jw | 0:b2805b6888dc | 1728 | -------------------------------------- |
robert_jw | 0:b2805b6888dc | 1729 | ---------- Checksum options ---------- |
robert_jw | 0:b2805b6888dc | 1730 | -------------------------------------- |
robert_jw | 0:b2805b6888dc | 1731 | */ |
robert_jw | 0:b2805b6888dc | 1732 | /** |
robert_jw | 0:b2805b6888dc | 1733 | * CHECKSUM_GEN_IP==1: Generate checksums in software for outgoing IP packets. |
robert_jw | 0:b2805b6888dc | 1734 | */ |
robert_jw | 0:b2805b6888dc | 1735 | #ifndef CHECKSUM_GEN_IP |
robert_jw | 0:b2805b6888dc | 1736 | #define CHECKSUM_GEN_IP 1 |
robert_jw | 0:b2805b6888dc | 1737 | #endif |
robert_jw | 0:b2805b6888dc | 1738 | |
robert_jw | 0:b2805b6888dc | 1739 | /** |
robert_jw | 0:b2805b6888dc | 1740 | * CHECKSUM_GEN_UDP==1: Generate checksums in software for outgoing UDP packets. |
robert_jw | 0:b2805b6888dc | 1741 | */ |
robert_jw | 0:b2805b6888dc | 1742 | #ifndef CHECKSUM_GEN_UDP |
robert_jw | 0:b2805b6888dc | 1743 | #define CHECKSUM_GEN_UDP 1 |
robert_jw | 0:b2805b6888dc | 1744 | #endif |
robert_jw | 0:b2805b6888dc | 1745 | |
robert_jw | 0:b2805b6888dc | 1746 | /** |
robert_jw | 0:b2805b6888dc | 1747 | * CHECKSUM_GEN_TCP==1: Generate checksums in software for outgoing TCP packets. |
robert_jw | 0:b2805b6888dc | 1748 | */ |
robert_jw | 0:b2805b6888dc | 1749 | #ifndef CHECKSUM_GEN_TCP |
robert_jw | 0:b2805b6888dc | 1750 | #define CHECKSUM_GEN_TCP 1 |
robert_jw | 0:b2805b6888dc | 1751 | #endif |
robert_jw | 0:b2805b6888dc | 1752 | |
robert_jw | 0:b2805b6888dc | 1753 | /** |
robert_jw | 0:b2805b6888dc | 1754 | * CHECKSUM_CHECK_IP==1: Check checksums in software for incoming IP packets. |
robert_jw | 0:b2805b6888dc | 1755 | */ |
robert_jw | 0:b2805b6888dc | 1756 | #ifndef CHECKSUM_CHECK_IP |
robert_jw | 0:b2805b6888dc | 1757 | #define CHECKSUM_CHECK_IP 1 |
robert_jw | 0:b2805b6888dc | 1758 | #endif |
robert_jw | 0:b2805b6888dc | 1759 | |
robert_jw | 0:b2805b6888dc | 1760 | /** |
robert_jw | 0:b2805b6888dc | 1761 | * CHECKSUM_CHECK_UDP==1: Check checksums in software for incoming UDP packets. |
robert_jw | 0:b2805b6888dc | 1762 | */ |
robert_jw | 0:b2805b6888dc | 1763 | #ifndef CHECKSUM_CHECK_UDP |
robert_jw | 0:b2805b6888dc | 1764 | #define CHECKSUM_CHECK_UDP 1 |
robert_jw | 0:b2805b6888dc | 1765 | #endif |
robert_jw | 0:b2805b6888dc | 1766 | |
robert_jw | 0:b2805b6888dc | 1767 | /** |
robert_jw | 0:b2805b6888dc | 1768 | * CHECKSUM_CHECK_TCP==1: Check checksums in software for incoming TCP packets. |
robert_jw | 0:b2805b6888dc | 1769 | */ |
robert_jw | 0:b2805b6888dc | 1770 | #ifndef CHECKSUM_CHECK_TCP |
robert_jw | 0:b2805b6888dc | 1771 | #define CHECKSUM_CHECK_TCP 1 |
robert_jw | 0:b2805b6888dc | 1772 | #endif |
robert_jw | 0:b2805b6888dc | 1773 | |
robert_jw | 0:b2805b6888dc | 1774 | /** |
robert_jw | 0:b2805b6888dc | 1775 | * LWIP_CHECKSUM_ON_COPY==1: Calculate checksum when copying data from |
robert_jw | 0:b2805b6888dc | 1776 | * application buffers to pbufs. |
robert_jw | 0:b2805b6888dc | 1777 | */ |
robert_jw | 0:b2805b6888dc | 1778 | #ifndef LWIP_CHECKSUM_ON_COPY |
robert_jw | 0:b2805b6888dc | 1779 | #define LWIP_CHECKSUM_ON_COPY 0 |
robert_jw | 0:b2805b6888dc | 1780 | #endif |
robert_jw | 0:b2805b6888dc | 1781 | |
robert_jw | 0:b2805b6888dc | 1782 | /* |
robert_jw | 0:b2805b6888dc | 1783 | --------------------------------------- |
robert_jw | 0:b2805b6888dc | 1784 | ---------- Debugging options ---------- |
robert_jw | 0:b2805b6888dc | 1785 | --------------------------------------- |
robert_jw | 0:b2805b6888dc | 1786 | */ |
robert_jw | 0:b2805b6888dc | 1787 | /** |
robert_jw | 0:b2805b6888dc | 1788 | * LWIP_DBG_MIN_LEVEL: After masking, the value of the debug is |
robert_jw | 0:b2805b6888dc | 1789 | * compared against this value. If it is smaller, then debugging |
robert_jw | 0:b2805b6888dc | 1790 | * messages are written. |
robert_jw | 0:b2805b6888dc | 1791 | */ |
robert_jw | 0:b2805b6888dc | 1792 | #ifndef LWIP_DBG_MIN_LEVEL |
robert_jw | 0:b2805b6888dc | 1793 | #define LWIP_DBG_MIN_LEVEL LWIP_DBG_LEVEL_ALL |
robert_jw | 0:b2805b6888dc | 1794 | #endif |
robert_jw | 0:b2805b6888dc | 1795 | |
robert_jw | 0:b2805b6888dc | 1796 | /** |
robert_jw | 0:b2805b6888dc | 1797 | * LWIP_DBG_TYPES_ON: A mask that can be used to globally enable/disable |
robert_jw | 0:b2805b6888dc | 1798 | * debug messages of certain types. |
robert_jw | 0:b2805b6888dc | 1799 | */ |
robert_jw | 0:b2805b6888dc | 1800 | #ifndef LWIP_DBG_TYPES_ON |
robert_jw | 0:b2805b6888dc | 1801 | #define LWIP_DBG_TYPES_ON LWIP_DBG_ON |
robert_jw | 0:b2805b6888dc | 1802 | #endif |
robert_jw | 0:b2805b6888dc | 1803 | |
robert_jw | 0:b2805b6888dc | 1804 | /** |
robert_jw | 0:b2805b6888dc | 1805 | * ETHARP_DEBUG: Enable debugging in etharp.c. |
robert_jw | 0:b2805b6888dc | 1806 | */ |
robert_jw | 0:b2805b6888dc | 1807 | #ifndef ETHARP_DEBUG |
robert_jw | 0:b2805b6888dc | 1808 | #define ETHARP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1809 | #endif |
robert_jw | 0:b2805b6888dc | 1810 | |
robert_jw | 0:b2805b6888dc | 1811 | /** |
robert_jw | 0:b2805b6888dc | 1812 | * NETIF_DEBUG: Enable debugging in netif.c. |
robert_jw | 0:b2805b6888dc | 1813 | */ |
robert_jw | 0:b2805b6888dc | 1814 | #ifndef NETIF_DEBUG |
robert_jw | 0:b2805b6888dc | 1815 | #define NETIF_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1816 | #endif |
robert_jw | 0:b2805b6888dc | 1817 | |
robert_jw | 0:b2805b6888dc | 1818 | /** |
robert_jw | 0:b2805b6888dc | 1819 | * PBUF_DEBUG: Enable debugging in pbuf.c. |
robert_jw | 0:b2805b6888dc | 1820 | */ |
robert_jw | 0:b2805b6888dc | 1821 | #ifndef PBUF_DEBUG |
robert_jw | 0:b2805b6888dc | 1822 | #define PBUF_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1823 | #endif |
robert_jw | 0:b2805b6888dc | 1824 | |
robert_jw | 0:b2805b6888dc | 1825 | /** |
robert_jw | 0:b2805b6888dc | 1826 | * API_LIB_DEBUG: Enable debugging in api_lib.c. |
robert_jw | 0:b2805b6888dc | 1827 | */ |
robert_jw | 0:b2805b6888dc | 1828 | #ifndef API_LIB_DEBUG |
robert_jw | 0:b2805b6888dc | 1829 | #define API_LIB_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1830 | #endif |
robert_jw | 0:b2805b6888dc | 1831 | |
robert_jw | 0:b2805b6888dc | 1832 | /** |
robert_jw | 0:b2805b6888dc | 1833 | * API_MSG_DEBUG: Enable debugging in api_msg.c. |
robert_jw | 0:b2805b6888dc | 1834 | */ |
robert_jw | 0:b2805b6888dc | 1835 | #ifndef API_MSG_DEBUG |
robert_jw | 0:b2805b6888dc | 1836 | #define API_MSG_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1837 | #endif |
robert_jw | 0:b2805b6888dc | 1838 | |
robert_jw | 0:b2805b6888dc | 1839 | /** |
robert_jw | 0:b2805b6888dc | 1840 | * SOCKETS_DEBUG: Enable debugging in sockets.c. |
robert_jw | 0:b2805b6888dc | 1841 | */ |
robert_jw | 0:b2805b6888dc | 1842 | #ifndef SOCKETS_DEBUG |
robert_jw | 0:b2805b6888dc | 1843 | #define SOCKETS_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1844 | #endif |
robert_jw | 0:b2805b6888dc | 1845 | |
robert_jw | 0:b2805b6888dc | 1846 | /** |
robert_jw | 0:b2805b6888dc | 1847 | * ICMP_DEBUG: Enable debugging in icmp.c. |
robert_jw | 0:b2805b6888dc | 1848 | */ |
robert_jw | 0:b2805b6888dc | 1849 | #ifndef ICMP_DEBUG |
robert_jw | 0:b2805b6888dc | 1850 | #define ICMP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1851 | #endif |
robert_jw | 0:b2805b6888dc | 1852 | |
robert_jw | 0:b2805b6888dc | 1853 | /** |
robert_jw | 0:b2805b6888dc | 1854 | * IGMP_DEBUG: Enable debugging in igmp.c. |
robert_jw | 0:b2805b6888dc | 1855 | */ |
robert_jw | 0:b2805b6888dc | 1856 | #ifndef IGMP_DEBUG |
robert_jw | 0:b2805b6888dc | 1857 | #define IGMP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1858 | #endif |
robert_jw | 0:b2805b6888dc | 1859 | |
robert_jw | 0:b2805b6888dc | 1860 | /** |
robert_jw | 0:b2805b6888dc | 1861 | * INET_DEBUG: Enable debugging in inet.c. |
robert_jw | 0:b2805b6888dc | 1862 | */ |
robert_jw | 0:b2805b6888dc | 1863 | #ifndef INET_DEBUG |
robert_jw | 0:b2805b6888dc | 1864 | #define INET_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1865 | #endif |
robert_jw | 0:b2805b6888dc | 1866 | |
robert_jw | 0:b2805b6888dc | 1867 | /** |
robert_jw | 0:b2805b6888dc | 1868 | * IP_DEBUG: Enable debugging for IP. |
robert_jw | 0:b2805b6888dc | 1869 | */ |
robert_jw | 0:b2805b6888dc | 1870 | #ifndef IP_DEBUG |
robert_jw | 0:b2805b6888dc | 1871 | #define IP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1872 | #endif |
robert_jw | 0:b2805b6888dc | 1873 | |
robert_jw | 0:b2805b6888dc | 1874 | /** |
robert_jw | 0:b2805b6888dc | 1875 | * IP_REASS_DEBUG: Enable debugging in ip_frag.c for both frag & reass. |
robert_jw | 0:b2805b6888dc | 1876 | */ |
robert_jw | 0:b2805b6888dc | 1877 | #ifndef IP_REASS_DEBUG |
robert_jw | 0:b2805b6888dc | 1878 | #define IP_REASS_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1879 | #endif |
robert_jw | 0:b2805b6888dc | 1880 | |
robert_jw | 0:b2805b6888dc | 1881 | /** |
robert_jw | 0:b2805b6888dc | 1882 | * RAW_DEBUG: Enable debugging in raw.c. |
robert_jw | 0:b2805b6888dc | 1883 | */ |
robert_jw | 0:b2805b6888dc | 1884 | #ifndef RAW_DEBUG |
robert_jw | 0:b2805b6888dc | 1885 | #define RAW_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1886 | #endif |
robert_jw | 0:b2805b6888dc | 1887 | |
robert_jw | 0:b2805b6888dc | 1888 | /** |
robert_jw | 0:b2805b6888dc | 1889 | * MEM_DEBUG: Enable debugging in mem.c. |
robert_jw | 0:b2805b6888dc | 1890 | */ |
robert_jw | 0:b2805b6888dc | 1891 | #ifndef MEM_DEBUG |
robert_jw | 0:b2805b6888dc | 1892 | #define MEM_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1893 | #endif |
robert_jw | 0:b2805b6888dc | 1894 | |
robert_jw | 0:b2805b6888dc | 1895 | /** |
robert_jw | 0:b2805b6888dc | 1896 | * MEMP_DEBUG: Enable debugging in memp.c. |
robert_jw | 0:b2805b6888dc | 1897 | */ |
robert_jw | 0:b2805b6888dc | 1898 | #ifndef MEMP_DEBUG |
robert_jw | 0:b2805b6888dc | 1899 | #define MEMP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1900 | #endif |
robert_jw | 0:b2805b6888dc | 1901 | |
robert_jw | 0:b2805b6888dc | 1902 | /** |
robert_jw | 0:b2805b6888dc | 1903 | * SYS_DEBUG: Enable debugging in sys.c. |
robert_jw | 0:b2805b6888dc | 1904 | */ |
robert_jw | 0:b2805b6888dc | 1905 | #ifndef SYS_DEBUG |
robert_jw | 0:b2805b6888dc | 1906 | #define SYS_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1907 | #endif |
robert_jw | 0:b2805b6888dc | 1908 | |
robert_jw | 0:b2805b6888dc | 1909 | /** |
robert_jw | 0:b2805b6888dc | 1910 | * TIMERS_DEBUG: Enable debugging in timers.c. |
robert_jw | 0:b2805b6888dc | 1911 | */ |
robert_jw | 0:b2805b6888dc | 1912 | #ifndef TIMERS_DEBUG |
robert_jw | 0:b2805b6888dc | 1913 | #define TIMERS_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1914 | #endif |
robert_jw | 0:b2805b6888dc | 1915 | |
robert_jw | 0:b2805b6888dc | 1916 | /** |
robert_jw | 0:b2805b6888dc | 1917 | * TCP_DEBUG: Enable debugging for TCP. |
robert_jw | 0:b2805b6888dc | 1918 | */ |
robert_jw | 0:b2805b6888dc | 1919 | #ifndef TCP_DEBUG |
robert_jw | 0:b2805b6888dc | 1920 | #define TCP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1921 | #endif |
robert_jw | 0:b2805b6888dc | 1922 | |
robert_jw | 0:b2805b6888dc | 1923 | /** |
robert_jw | 0:b2805b6888dc | 1924 | * TCP_INPUT_DEBUG: Enable debugging in tcp_in.c for incoming debug. |
robert_jw | 0:b2805b6888dc | 1925 | */ |
robert_jw | 0:b2805b6888dc | 1926 | #ifndef TCP_INPUT_DEBUG |
robert_jw | 0:b2805b6888dc | 1927 | #define TCP_INPUT_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1928 | #endif |
robert_jw | 0:b2805b6888dc | 1929 | |
robert_jw | 0:b2805b6888dc | 1930 | /** |
robert_jw | 0:b2805b6888dc | 1931 | * TCP_FR_DEBUG: Enable debugging in tcp_in.c for fast retransmit. |
robert_jw | 0:b2805b6888dc | 1932 | */ |
robert_jw | 0:b2805b6888dc | 1933 | #ifndef TCP_FR_DEBUG |
robert_jw | 0:b2805b6888dc | 1934 | #define TCP_FR_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1935 | #endif |
robert_jw | 0:b2805b6888dc | 1936 | |
robert_jw | 0:b2805b6888dc | 1937 | /** |
robert_jw | 0:b2805b6888dc | 1938 | * TCP_RTO_DEBUG: Enable debugging in TCP for retransmit |
robert_jw | 0:b2805b6888dc | 1939 | * timeout. |
robert_jw | 0:b2805b6888dc | 1940 | */ |
robert_jw | 0:b2805b6888dc | 1941 | #ifndef TCP_RTO_DEBUG |
robert_jw | 0:b2805b6888dc | 1942 | #define TCP_RTO_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1943 | #endif |
robert_jw | 0:b2805b6888dc | 1944 | |
robert_jw | 0:b2805b6888dc | 1945 | /** |
robert_jw | 0:b2805b6888dc | 1946 | * TCP_CWND_DEBUG: Enable debugging for TCP congestion window. |
robert_jw | 0:b2805b6888dc | 1947 | */ |
robert_jw | 0:b2805b6888dc | 1948 | #ifndef TCP_CWND_DEBUG |
robert_jw | 0:b2805b6888dc | 1949 | #define TCP_CWND_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1950 | #endif |
robert_jw | 0:b2805b6888dc | 1951 | |
robert_jw | 0:b2805b6888dc | 1952 | /** |
robert_jw | 0:b2805b6888dc | 1953 | * TCP_WND_DEBUG: Enable debugging in tcp_in.c for window updating. |
robert_jw | 0:b2805b6888dc | 1954 | */ |
robert_jw | 0:b2805b6888dc | 1955 | #ifndef TCP_WND_DEBUG |
robert_jw | 0:b2805b6888dc | 1956 | #define TCP_WND_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1957 | #endif |
robert_jw | 0:b2805b6888dc | 1958 | |
robert_jw | 0:b2805b6888dc | 1959 | /** |
robert_jw | 0:b2805b6888dc | 1960 | * TCP_OUTPUT_DEBUG: Enable debugging in tcp_out.c output functions. |
robert_jw | 0:b2805b6888dc | 1961 | */ |
robert_jw | 0:b2805b6888dc | 1962 | #ifndef TCP_OUTPUT_DEBUG |
robert_jw | 0:b2805b6888dc | 1963 | #define TCP_OUTPUT_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1964 | #endif |
robert_jw | 0:b2805b6888dc | 1965 | |
robert_jw | 0:b2805b6888dc | 1966 | /** |
robert_jw | 0:b2805b6888dc | 1967 | * TCP_RST_DEBUG: Enable debugging for TCP with the RST message. |
robert_jw | 0:b2805b6888dc | 1968 | */ |
robert_jw | 0:b2805b6888dc | 1969 | #ifndef TCP_RST_DEBUG |
robert_jw | 0:b2805b6888dc | 1970 | #define TCP_RST_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1971 | #endif |
robert_jw | 0:b2805b6888dc | 1972 | |
robert_jw | 0:b2805b6888dc | 1973 | /** |
robert_jw | 0:b2805b6888dc | 1974 | * TCP_QLEN_DEBUG: Enable debugging for TCP queue lengths. |
robert_jw | 0:b2805b6888dc | 1975 | */ |
robert_jw | 0:b2805b6888dc | 1976 | #ifndef TCP_QLEN_DEBUG |
robert_jw | 0:b2805b6888dc | 1977 | #define TCP_QLEN_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1978 | #endif |
robert_jw | 0:b2805b6888dc | 1979 | |
robert_jw | 0:b2805b6888dc | 1980 | /** |
robert_jw | 0:b2805b6888dc | 1981 | * UDP_DEBUG: Enable debugging in UDP. |
robert_jw | 0:b2805b6888dc | 1982 | */ |
robert_jw | 0:b2805b6888dc | 1983 | #ifndef UDP_DEBUG |
robert_jw | 0:b2805b6888dc | 1984 | #define UDP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1985 | #endif |
robert_jw | 0:b2805b6888dc | 1986 | |
robert_jw | 0:b2805b6888dc | 1987 | /** |
robert_jw | 0:b2805b6888dc | 1988 | * TCPIP_DEBUG: Enable debugging in tcpip.c. |
robert_jw | 0:b2805b6888dc | 1989 | */ |
robert_jw | 0:b2805b6888dc | 1990 | #ifndef TCPIP_DEBUG |
robert_jw | 0:b2805b6888dc | 1991 | #define TCPIP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1992 | #endif |
robert_jw | 0:b2805b6888dc | 1993 | |
robert_jw | 0:b2805b6888dc | 1994 | /** |
robert_jw | 0:b2805b6888dc | 1995 | * PPP_DEBUG: Enable debugging for PPP. |
robert_jw | 0:b2805b6888dc | 1996 | */ |
robert_jw | 0:b2805b6888dc | 1997 | #ifndef PPP_DEBUG |
robert_jw | 0:b2805b6888dc | 1998 | #define PPP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 1999 | #endif |
robert_jw | 0:b2805b6888dc | 2000 | |
robert_jw | 0:b2805b6888dc | 2001 | /** |
robert_jw | 0:b2805b6888dc | 2002 | * SLIP_DEBUG: Enable debugging in slipif.c. |
robert_jw | 0:b2805b6888dc | 2003 | */ |
robert_jw | 0:b2805b6888dc | 2004 | #ifndef SLIP_DEBUG |
robert_jw | 0:b2805b6888dc | 2005 | #define SLIP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 2006 | #endif |
robert_jw | 0:b2805b6888dc | 2007 | |
robert_jw | 0:b2805b6888dc | 2008 | /** |
robert_jw | 0:b2805b6888dc | 2009 | * DHCP_DEBUG: Enable debugging in dhcp.c. |
robert_jw | 0:b2805b6888dc | 2010 | */ |
robert_jw | 0:b2805b6888dc | 2011 | #ifndef DHCP_DEBUG |
robert_jw | 0:b2805b6888dc | 2012 | #define DHCP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 2013 | #endif |
robert_jw | 0:b2805b6888dc | 2014 | |
robert_jw | 0:b2805b6888dc | 2015 | /** |
robert_jw | 0:b2805b6888dc | 2016 | * AUTOIP_DEBUG: Enable debugging in autoip.c. |
robert_jw | 0:b2805b6888dc | 2017 | */ |
robert_jw | 0:b2805b6888dc | 2018 | #ifndef AUTOIP_DEBUG |
robert_jw | 0:b2805b6888dc | 2019 | #define AUTOIP_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 2020 | #endif |
robert_jw | 0:b2805b6888dc | 2021 | |
robert_jw | 0:b2805b6888dc | 2022 | /** |
robert_jw | 0:b2805b6888dc | 2023 | * SNMP_MSG_DEBUG: Enable debugging for SNMP messages. |
robert_jw | 0:b2805b6888dc | 2024 | */ |
robert_jw | 0:b2805b6888dc | 2025 | #ifndef SNMP_MSG_DEBUG |
robert_jw | 0:b2805b6888dc | 2026 | #define SNMP_MSG_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 2027 | #endif |
robert_jw | 0:b2805b6888dc | 2028 | |
robert_jw | 0:b2805b6888dc | 2029 | /** |
robert_jw | 0:b2805b6888dc | 2030 | * SNMP_MIB_DEBUG: Enable debugging for SNMP MIBs. |
robert_jw | 0:b2805b6888dc | 2031 | */ |
robert_jw | 0:b2805b6888dc | 2032 | #ifndef SNMP_MIB_DEBUG |
robert_jw | 0:b2805b6888dc | 2033 | #define SNMP_MIB_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 2034 | #endif |
robert_jw | 0:b2805b6888dc | 2035 | |
robert_jw | 0:b2805b6888dc | 2036 | /** |
robert_jw | 0:b2805b6888dc | 2037 | * DNS_DEBUG: Enable debugging for DNS. |
robert_jw | 0:b2805b6888dc | 2038 | */ |
robert_jw | 0:b2805b6888dc | 2039 | #ifndef DNS_DEBUG |
robert_jw | 0:b2805b6888dc | 2040 | #define DNS_DEBUG LWIP_DBG_OFF |
robert_jw | 0:b2805b6888dc | 2041 | #endif |
robert_jw | 0:b2805b6888dc | 2042 | |
robert_jw | 0:b2805b6888dc | 2043 | #endif /* __LWIP_OPT_H__ */ |