1 /****************************************************************//** 2 * 3 * @file tftp_opts.h 4 * 5 * @author Logan Gunthorpe <[email protected]> 6 * 7 * @brief Trivial File Transfer Protocol (RFC 1350) implementation options 8 * 9 * Copyright (c) Deltatee Enterprises Ltd. 2013 10 * All rights reserved. 11 * 12 ********************************************************************/ 13 14 /* 15 * Redistribution and use in source and binary forms, with or without 16 * modification,are permitted provided that the following conditions are met: 17 * 18 * 1. Redistributions of source code must retain the above copyright notice, 19 * this list of conditions and the following disclaimer. 20 * 2. Redistributions in binary form must reproduce the above copyright notice, 21 * this list of conditions and the following disclaimer in the documentation 22 * and/or other materials provided with the distribution. 23 * 3. The name of the author may not be used to endorse or promote products 24 * derived from this software without specific prior written permission. 25 * 26 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED 27 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 28 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO 29 * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 30 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED 31 * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 32 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 33 * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 34 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 35 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 36 * 37 * Author: Logan Gunthorpe <[email protected]> 38 * 39 */ 40 41 #ifndef LWIP_HDR_APPS_TFTP_OPTS_H 42 #define LWIP_HDR_APPS_TFTP_OPTS_H 43 44 #include "lwip/opt.h" 45 46 /** 47 * @defgroup tftp_opts Options 48 * @ingroup tftp 49 * @{ 50 */ 51 52 /** 53 * Enable TFTP debug messages 54 */ 55 #if !defined TFTP_DEBUG || defined __DOXYGEN__ 56 #define TFTP_DEBUG LWIP_DBG_ON 57 #endif 58 59 /** 60 * TFTP server port 61 */ 62 #if !defined TFTP_PORT || defined __DOXYGEN__ 63 #define TFTP_PORT 69 64 #endif 65 66 /** 67 * TFTP timeout 68 */ 69 #if !defined TFTP_TIMEOUT_MSECS || defined __DOXYGEN__ 70 #define TFTP_TIMEOUT_MSECS 10000 71 #endif 72 73 /** 74 * Max. number of retries when a file is read from server 75 */ 76 #if !defined TFTP_MAX_RETRIES || defined __DOXYGEN__ 77 #define TFTP_MAX_RETRIES 5 78 #endif 79 80 /** 81 * TFTP timer cyclic interval 82 */ 83 #if !defined TFTP_TIMER_MSECS || defined __DOXYGEN__ 84 #define TFTP_TIMER_MSECS 50 85 #endif 86 87 /** 88 * Max. length of TFTP filename 89 */ 90 #if !defined TFTP_MAX_FILENAME_LEN || defined __DOXYGEN__ 91 #define TFTP_MAX_FILENAME_LEN 20 92 #endif 93 94 /** 95 * Max. length of TFTP mode 96 */ 97 #if !defined TFTP_MAX_MODE_LEN || defined __DOXYGEN__ 98 #define TFTP_MAX_MODE_LEN 7 99 #endif 100 101 /** 102 * @} 103 */ 104 105 #endif /* LWIP_HDR_APPS_TFTP_OPTS_H */ 106