Ethernet test for ECE 4180 and others to find your IP address and do a simple HTTP GET request over port 80.

Dependencies:   mbed Socket lwip-eth lwip-sys lwip

Committer:
mkersh3
Date:
Thu Apr 04 05:26:09 2013 +0000
Revision:
0:e7ca326e76ee
Ethernet Test for ECE4180 and others to find their IP Address and do a simple HTTP GET request over port 80.

Who changed what in which revision?

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