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