GigaDevice_test/FreeRTOS/source/include/FreeRTOSIPConfig.h

120 lines
5.1 KiB
C

/*
* FreeRTOS+TCP V3.1.0
* Copyright (C) 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* http://aws.amazon.com/freertos
* http://www.FreeRTOS.org
*/
/*****************************************************************************
*
* See the following URL for configuration information.
* http://www.freertos.org/FreeRTOS-Plus/FreeRTOS_Plus_TCP/TCP_IP_Configuration.html
*
*****************************************************************************/
#ifndef FREERTOS_IP_CONFIG_H
#define FREERTOS_IP_CONFIG_H
/* Empty configuration file to check the build with default configuration. */
/* It is not sensible for this macro to have a default value as it is hardware
* dependent. */
#define ipconfigBYTE_ORDER pdFREERTOS_LITTLE_ENDIAN
#define ipconfigNUM_NETWORK_BUFFER_DESCRIPTORS 4
#define ipconfigUSE_NETWORK_EVENT_HOOK 1
#define ipconfigUSE_DHCP 1
#define ipconfigUSE_DHCP_HOOK 1
#define ipconfigUSE_DNS_CACHE 1
#define ipconfigMAC_INTERRUPT_PRIORITY ( configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY )
#define ipconfigDHCP_REGISTER_HOSTNAME 1
#define ipconfigUSE_DNS 1
#ifndef DEBUG
#warning Define ipconfigWATCHDOG_TIMER()
/* This macro will be called in every loop the IP-task makes. It may be
* replaced by user-code that triggers a watchdog */
#define ipconfigWATCHDOG_TIMER()
#endif
/* The option 'ipconfigUSE_CALLBACKS' allows to assign specific application
* hooks to a socket. Each hook will be set with a specific socket option:
*
* FREERTOS_SO_TCP_CONN_HANDLER * Callback for (dis) connection events.
* * Supply pointer to 'F_TCP_UDP_Handler_t'
* FREERTOS_SO_TCP_RECV_HANDLER * Callback for receiving TCP data.
* * Supply pointer to 'F_TCP_UDP_Handler_t'
* FREERTOS_SO_TCP_SENT_HANDLER * Callback for sending TCP data.
* * Supply pointer to 'F_TCP_UDP_Handler_t'
* FREERTOS_SO_UDP_RECV_HANDLER * Callback for receiving UDP data.
* * Supply pointer to 'F_TCP_UDP_Handler_t'
* FREERTOS_SO_UDP_SENT_HANDLER * Callback for sending UDP data.
* * Supply pointer to 'F_TCP_UDP_Handler_t'
*
* Note that the call-back functions will run in the IP-task, so very little
* things can be done. Better not to call any networking API, because that
* could easily lead to a deadlock situation.
*/
#define ipconfigUSE_CALLBACKS ( 0 )
/* When non-zero, the buffers passed to xNetworkInterfaceOutput() will be passed
* directly to DMA. As soon as sending is ready, the buffers must be released by
* calling vReleaseNetworkBufferAndDescriptor(). */
#define ipconfigZERO_COPY_TX_DRIVER ( 0 )
/* When enabled, the network interface will pass the network buffers directly to
* the DMA descriptors. When a packet has been received, the function
* pxPacketBuffer_to_NetworkBuffer() will translate a buffer address to a
* network packet, so it can be passed to the IP-task. */
#define ipconfigZERO_COPY_RX_DRIVER ( 0 )
//#define ipconfigUSE_LLMNR 1
//#define ipconfigUSE_NBNS 1
//#define ipconfigETHERNET_DRIVER_FILTERS_FRAME_TYPES 1
//#define ipconfigDRIVER_INCLUDED_TX_IP_CHECKSUM 1
//#define ipconfigDRIVER_INCLUDED_RX_IP_CHECKSUM 1
//#define ipconfigZERO_COPY_RX_DRIVER 1
//#define ipconfigZERO_COPY_TX_DRIVER 1
//#define ipconfigUSE_LINKED_RX_MESSAGES 1
//#define ipconfigUDP_MAX_RX_PACKETS 10
//#define ipconfigSUPPORT_SIGNALS 1
#define ipconfigUSE_TCP_WIN 0
//#define ipconfigNETWORK_MTU 586
//#define ipconfigNUM_NETWORK_BUFFER_DESCRIPTORS 10U
#ifdef DEBUG
#define ipconfigHAS_DEBUG_PRINTF 1
#define ipconfigHAS_PRINTF 1
#ifndef ipconfigHAS_DEBUG_PRINTF
#define FreeRTOS_debug_printf( X )
#else
#define FreeRTOS_debug_printf( X ) printf X
#endif
#ifndef ipconfigHAS_PRINTF
#define FreeRTOS_printf( X )
#else
#define FreeRTOS_printf( X ) printf X
#endif
#endif
#endif
#include "IPTraceMacro.h"