Patch for EthernetInterface library using the K64F

Committer:
loopsva
Date:
Mon Jun 30 17:27:46 2014 +0000
Revision:
0:87a63595da37
Patch for EthernetInterface using the K64F

Who changed what in which revision?

UserRevisionLine numberNew contents of line
loopsva 0:87a63595da37 1 /**********************************************************************
loopsva 0:87a63595da37 2 * $Id$ lpc_emac_config.h 2011-11-20
loopsva 0:87a63595da37 3 *//**
loopsva 0:87a63595da37 4 * @file lpc_emac_config.h
loopsva 0:87a63595da37 5 * @brief PHY and EMAC configuration file
loopsva 0:87a63595da37 6 * @version 1.0
loopsva 0:87a63595da37 7 * @date 20 Nov. 2011
loopsva 0:87a63595da37 8 * @author NXP MCU SW Application Team
loopsva 0:87a63595da37 9 *
loopsva 0:87a63595da37 10 * Copyright(C) 2011, NXP Semiconductor
loopsva 0:87a63595da37 11 * All rights reserved.
loopsva 0:87a63595da37 12 *
loopsva 0:87a63595da37 13 ***********************************************************************
loopsva 0:87a63595da37 14 * Software that is described herein is for illustrative purposes only
loopsva 0:87a63595da37 15 * which provides customers with programming information regarding the
loopsva 0:87a63595da37 16 * products. This software is supplied "AS IS" without any warranties.
loopsva 0:87a63595da37 17 * NXP Semiconductors assumes no responsibility or liability for the
loopsva 0:87a63595da37 18 * use of the software, conveys no license or title under any patent,
loopsva 0:87a63595da37 19 * copyright, or mask work right to the product. NXP Semiconductors
loopsva 0:87a63595da37 20 * reserves the right to make changes in the software without
loopsva 0:87a63595da37 21 * notification. NXP Semiconductors also make no representation or
loopsva 0:87a63595da37 22 * warranty that such application will be suitable for the specified
loopsva 0:87a63595da37 23 * use without further testing or modification.
loopsva 0:87a63595da37 24 **********************************************************************/
loopsva 0:87a63595da37 25
loopsva 0:87a63595da37 26 #ifndef __LPC_EMAC_CONFIG_H
loopsva 0:87a63595da37 27 #define __LPC_EMAC_CONFIG_H
loopsva 0:87a63595da37 28
loopsva 0:87a63595da37 29 #include "lwip/opt.h"
loopsva 0:87a63595da37 30
loopsva 0:87a63595da37 31 #ifdef __cplusplus
loopsva 0:87a63595da37 32 extern "C"
loopsva 0:87a63595da37 33 {
loopsva 0:87a63595da37 34 #endif
loopsva 0:87a63595da37 35
loopsva 0:87a63595da37 36 /** @defgroup lwip_phy_config LWIP PHY configuration
loopsva 0:87a63595da37 37 * @ingroup lwip_phy
loopsva 0:87a63595da37 38 *
loopsva 0:87a63595da37 39 * Configuration options for the PHY connected to the LPC EMAC.
loopsva 0:87a63595da37 40 * @{
loopsva 0:87a63595da37 41 */
loopsva 0:87a63595da37 42
loopsva 0:87a63595da37 43 /** \brief The PHY address connected the to MII/RMII
loopsva 0:87a63595da37 44 */
loopsva 0:87a63595da37 45 #define LPC_PHYDEF_PHYADDR 1 /**< The PHY address on the PHY device. */
loopsva 0:87a63595da37 46
loopsva 0:87a63595da37 47 /** \brief Enable autonegotiation mode.
loopsva 0:87a63595da37 48 * If this is enabled, the PHY will attempt to auto-negotiate the
loopsva 0:87a63595da37 49 * best link mode if the PHY supports it. If this is not enabled,
loopsva 0:87a63595da37 50 * the PHY_USE_FULL_DUPLEX and PHY_USE_100MBS defines will be
loopsva 0:87a63595da37 51 * used to select the link mode. Note that auto-negotiation may
loopsva 0:87a63595da37 52 * take a few seconds to complete.
loopsva 0:87a63595da37 53 */
loopsva 0:87a63595da37 54 #define PHY_USE_AUTONEG 1 /**< Enables auto-negotiation mode. */
loopsva 0:87a63595da37 55
loopsva 0:87a63595da37 56 /** \brief Sets up the PHY interface to either full duplex operation or
loopsva 0:87a63595da37 57 * half duplex operation if PHY_USE_AUTONEG is not enabled.
loopsva 0:87a63595da37 58 */
loopsva 0:87a63595da37 59 #define PHY_USE_FULL_DUPLEX 1 /**< Sets duplex mode to full. */
loopsva 0:87a63595da37 60
loopsva 0:87a63595da37 61 /** \brief Sets up the PHY interface to either 100MBS operation or 10MBS
loopsva 0:87a63595da37 62 * operation if PHY_USE_AUTONEG is not enabled.
loopsva 0:87a63595da37 63 */
loopsva 0:87a63595da37 64 #define PHY_USE_100MBS 1 /**< Sets data rate to 100Mbps. */
loopsva 0:87a63595da37 65
loopsva 0:87a63595da37 66 /**
loopsva 0:87a63595da37 67 * @}
loopsva 0:87a63595da37 68 */
loopsva 0:87a63595da37 69
loopsva 0:87a63595da37 70 /** @defgroup lwip_emac_config LWIP EMAC configuration
loopsva 0:87a63595da37 71 * @ingroup lwip_emac
loopsva 0:87a63595da37 72 *
loopsva 0:87a63595da37 73 * Configuration options for the LPC EMAC.
loopsva 0:87a63595da37 74 * @{
loopsva 0:87a63595da37 75 */
loopsva 0:87a63595da37 76
loopsva 0:87a63595da37 77 /** \brief Selects RMII or MII connection type in the EMAC peripheral
loopsva 0:87a63595da37 78 */
loopsva 0:87a63595da37 79 #define LPC_EMAC_RMII 1 /**< Use the RMII or MII driver variant .*/
loopsva 0:87a63595da37 80
loopsva 0:87a63595da37 81 /** \brief Defines the number of descriptors used for RX. This
loopsva 0:87a63595da37 82 * must be a minimum value of 2.
loopsva 0:87a63595da37 83 */
loopsva 0:87a63595da37 84 #define LPC_NUM_BUFF_RXDESCS 3
loopsva 0:87a63595da37 85
loopsva 0:87a63595da37 86 /** \brief Defines the number of descriptors used for TX. Must
loopsva 0:87a63595da37 87 * be a minimum value of 2.
loopsva 0:87a63595da37 88 */
loopsva 0:87a63595da37 89 #define LPC_NUM_BUFF_TXDESCS (TCP_SND_QUEUELEN + 1)
loopsva 0:87a63595da37 90
loopsva 0:87a63595da37 91 /** \brief Set this define to 1 to enable bounce buffers for transmit pbufs
loopsva 0:87a63595da37 92 * that cannot be sent via the zero-copy method. Some chained pbufs
loopsva 0:87a63595da37 93 * may have a payload address that links to an area of memory that
loopsva 0:87a63595da37 94 * cannot be used for transmit DMA operations. If this define is
loopsva 0:87a63595da37 95 * set to 1, an extra check will be made with the pbufs. If a buffer
loopsva 0:87a63595da37 96 * is determined to be non-usable for zero-copy, a temporary bounce
loopsva 0:87a63595da37 97 * buffer will be created and used instead.
loopsva 0:87a63595da37 98 */
loopsva 0:87a63595da37 99 #define LPC_TX_PBUF_BOUNCE_EN 1
loopsva 0:87a63595da37 100
loopsva 0:87a63595da37 101 /**
loopsva 0:87a63595da37 102 * @}
loopsva 0:87a63595da37 103 */
loopsva 0:87a63595da37 104
loopsva 0:87a63595da37 105 #ifdef __cplusplus
loopsva 0:87a63595da37 106 }
loopsva 0:87a63595da37 107 #endif
loopsva 0:87a63595da37 108
loopsva 0:87a63595da37 109 #endif /* __LPC_EMAC_CONFIG_H */
loopsva 0:87a63595da37 110
loopsva 0:87a63595da37 111 /* --------------------------------- End Of File ------------------------------ */