HTTPClient using static IP

Dependencies:   mbed

Committer:
mr_q
Date:
Mon May 30 11:53:37 2011 +0000
Revision:
0:d8f2f7d5f31b
v0.01 Draft

Who changed what in which revision?

UserRevisionLine numberNew contents of line
mr_q 0:d8f2f7d5f31b 1 /*
mr_q 0:d8f2f7d5f31b 2 * Copyright (c) 2001-2004 Swedish Institute of Computer Science.
mr_q 0:d8f2f7d5f31b 3 * All rights reserved.
mr_q 0:d8f2f7d5f31b 4 *
mr_q 0:d8f2f7d5f31b 5 * Redistribution and use in source and binary forms, with or without modification,
mr_q 0:d8f2f7d5f31b 6 * are permitted provided that the following conditions are met:
mr_q 0:d8f2f7d5f31b 7 *
mr_q 0:d8f2f7d5f31b 8 * 1. Redistributions of source code must retain the above copyright notice,
mr_q 0:d8f2f7d5f31b 9 * this list of conditions and the following disclaimer.
mr_q 0:d8f2f7d5f31b 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
mr_q 0:d8f2f7d5f31b 11 * this list of conditions and the following disclaimer in the documentation
mr_q 0:d8f2f7d5f31b 12 * and/or other materials provided with the distribution.
mr_q 0:d8f2f7d5f31b 13 * 3. The name of the author may not be used to endorse or promote products
mr_q 0:d8f2f7d5f31b 14 * derived from this software without specific prior written permission.
mr_q 0:d8f2f7d5f31b 15 *
mr_q 0:d8f2f7d5f31b 16 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
mr_q 0:d8f2f7d5f31b 17 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
mr_q 0:d8f2f7d5f31b 18 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT
mr_q 0:d8f2f7d5f31b 19 * SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
mr_q 0:d8f2f7d5f31b 20 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
mr_q 0:d8f2f7d5f31b 21 * OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
mr_q 0:d8f2f7d5f31b 22 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
mr_q 0:d8f2f7d5f31b 23 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
mr_q 0:d8f2f7d5f31b 24 * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
mr_q 0:d8f2f7d5f31b 25 * OF SUCH DAMAGE.
mr_q 0:d8f2f7d5f31b 26 *
mr_q 0:d8f2f7d5f31b 27 * This file is part of the lwIP TCP/IP stack.
mr_q 0:d8f2f7d5f31b 28 *
mr_q 0:d8f2f7d5f31b 29 * Author: Adam Dunkels <adam@sics.se>
mr_q 0:d8f2f7d5f31b 30 *
mr_q 0:d8f2f7d5f31b 31 */
mr_q 0:d8f2f7d5f31b 32 #ifndef __LWIP_ERR_H__
mr_q 0:d8f2f7d5f31b 33 #define __LWIP_ERR_H__
mr_q 0:d8f2f7d5f31b 34
mr_q 0:d8f2f7d5f31b 35 #include "lwip/opt.h"
mr_q 0:d8f2f7d5f31b 36 #include "lwip/arch.h"
mr_q 0:d8f2f7d5f31b 37
mr_q 0:d8f2f7d5f31b 38 #ifdef __cplusplus
mr_q 0:d8f2f7d5f31b 39 extern "C" {
mr_q 0:d8f2f7d5f31b 40 #endif
mr_q 0:d8f2f7d5f31b 41
mr_q 0:d8f2f7d5f31b 42 /** Define LWIP_ERR_T in cc.h if you want to use
mr_q 0:d8f2f7d5f31b 43 * a different type for your platform (must be signed). */
mr_q 0:d8f2f7d5f31b 44 #ifdef LWIP_ERR_T
mr_q 0:d8f2f7d5f31b 45 typedef LWIP_ERR_T err_t;
mr_q 0:d8f2f7d5f31b 46 #else /* LWIP_ERR_T */
mr_q 0:d8f2f7d5f31b 47 typedef s8_t err_t;
mr_q 0:d8f2f7d5f31b 48 #endif /* LWIP_ERR_T*/
mr_q 0:d8f2f7d5f31b 49
mr_q 0:d8f2f7d5f31b 50 /* Definitions for error constants. */
mr_q 0:d8f2f7d5f31b 51
mr_q 0:d8f2f7d5f31b 52 #define ERR_OK 0 /* No error, everything OK. */
mr_q 0:d8f2f7d5f31b 53 #define ERR_MEM -1 /* Out of memory error. */
mr_q 0:d8f2f7d5f31b 54 #define ERR_BUF -2 /* Buffer error. */
mr_q 0:d8f2f7d5f31b 55 #define ERR_TIMEOUT -3 /* Timeout. */
mr_q 0:d8f2f7d5f31b 56 #define ERR_RTE -4 /* Routing problem. */
mr_q 0:d8f2f7d5f31b 57 #define ERR_INPROGRESS -5 /* Operation in progress */
mr_q 0:d8f2f7d5f31b 58 #define ERR_VAL -6 /* Illegal value. */
mr_q 0:d8f2f7d5f31b 59 #define ERR_WOULDBLOCK -7 /* Operation would block. */
mr_q 0:d8f2f7d5f31b 60
mr_q 0:d8f2f7d5f31b 61 #define ERR_IS_FATAL(e) ((e) < ERR_VAL)
mr_q 0:d8f2f7d5f31b 62
mr_q 0:d8f2f7d5f31b 63 #define ERR_ABRT -8 /* Connection aborted. */
mr_q 0:d8f2f7d5f31b 64 #define ERR_RST -9 /* Connection reset. */
mr_q 0:d8f2f7d5f31b 65 #define ERR_CLSD -10 /* Connection closed. */
mr_q 0:d8f2f7d5f31b 66 #define ERR_CONN -11 /* Not connected. */
mr_q 0:d8f2f7d5f31b 67
mr_q 0:d8f2f7d5f31b 68 #define ERR_ARG -12 /* Illegal argument. */
mr_q 0:d8f2f7d5f31b 69
mr_q 0:d8f2f7d5f31b 70 #define ERR_USE -13 /* Address in use. */
mr_q 0:d8f2f7d5f31b 71
mr_q 0:d8f2f7d5f31b 72 #define ERR_IF -14 /* Low-level netif error */
mr_q 0:d8f2f7d5f31b 73 #define ERR_ISCONN -15 /* Already connected. */
mr_q 0:d8f2f7d5f31b 74
mr_q 0:d8f2f7d5f31b 75
mr_q 0:d8f2f7d5f31b 76 #ifdef LWIP_DEBUG
mr_q 0:d8f2f7d5f31b 77 extern const char *lwip_strerr(err_t err);
mr_q 0:d8f2f7d5f31b 78 #else
mr_q 0:d8f2f7d5f31b 79 #define lwip_strerr(x) ""
mr_q 0:d8f2f7d5f31b 80 #endif /* LWIP_DEBUG */
mr_q 0:d8f2f7d5f31b 81
mr_q 0:d8f2f7d5f31b 82 #ifdef __cplusplus
mr_q 0:d8f2f7d5f31b 83 }
mr_q 0:d8f2f7d5f31b 84 #endif
mr_q 0:d8f2f7d5f31b 85
mr_q 0:d8f2f7d5f31b 86 #endif /* __LWIP_ERR_H__ */