Web server based weather station using Sparkfun Weather Meters.

Dependencies:   FatFileSystem mbed WeatherMeters SDFileSystem

Committer:
AdamGreen
Date:
Sat Feb 25 03:28:05 2012 +0000
Revision:
1:c7958aa34fa1
Parent:
0:616601bde9fb
Use published libraries where possible.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
AdamGreen 0:616601bde9fb 1 /*****************************************************************************
AdamGreen 0:616601bde9fb 2 * ipcp.h - PPP IP NCP: Internet Protocol Network Control Protocol header file.
AdamGreen 0:616601bde9fb 3 *
AdamGreen 0:616601bde9fb 4 * Copyright (c) 2003 by Marc Boucher, Services Informatiques (MBSI) inc.
AdamGreen 0:616601bde9fb 5 * portions Copyright (c) 1997 Global Election Systems Inc.
AdamGreen 0:616601bde9fb 6 *
AdamGreen 0:616601bde9fb 7 * The authors hereby grant permission to use, copy, modify, distribute,
AdamGreen 0:616601bde9fb 8 * and license this software and its documentation for any purpose, provided
AdamGreen 0:616601bde9fb 9 * that existing copyright notices are retained in all copies and that this
AdamGreen 0:616601bde9fb 10 * notice and the following disclaimer are included verbatim in any
AdamGreen 0:616601bde9fb 11 * distributions. No written agreement, license, or royalty fee is required
AdamGreen 0:616601bde9fb 12 * for any of the authorized uses.
AdamGreen 0:616601bde9fb 13 *
AdamGreen 0:616601bde9fb 14 * THIS SOFTWARE IS PROVIDED BY THE CONTRIBUTORS *AS IS* AND ANY EXPRESS OR
AdamGreen 0:616601bde9fb 15 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
AdamGreen 0:616601bde9fb 16 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
AdamGreen 0:616601bde9fb 17 * IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
AdamGreen 0:616601bde9fb 18 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
AdamGreen 0:616601bde9fb 19 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
AdamGreen 0:616601bde9fb 20 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
AdamGreen 0:616601bde9fb 21 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
AdamGreen 0:616601bde9fb 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
AdamGreen 0:616601bde9fb 23 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
AdamGreen 0:616601bde9fb 24 *
AdamGreen 0:616601bde9fb 25 ******************************************************************************
AdamGreen 0:616601bde9fb 26 * REVISION HISTORY
AdamGreen 0:616601bde9fb 27 *
AdamGreen 0:616601bde9fb 28 * 03-01-01 Marc Boucher <marc@mbsi.ca>
AdamGreen 0:616601bde9fb 29 * Ported to lwIP.
AdamGreen 0:616601bde9fb 30 * 97-12-04 Guy Lancaster <glanca@gesn.com>, Global Election Systems Inc.
AdamGreen 0:616601bde9fb 31 * Original derived from BSD codes.
AdamGreen 0:616601bde9fb 32 *****************************************************************************/
AdamGreen 0:616601bde9fb 33 /*
AdamGreen 0:616601bde9fb 34 * ipcp.h - IP Control Protocol definitions.
AdamGreen 0:616601bde9fb 35 *
AdamGreen 0:616601bde9fb 36 * Copyright (c) 1989 Carnegie Mellon University.
AdamGreen 0:616601bde9fb 37 * All rights reserved.
AdamGreen 0:616601bde9fb 38 *
AdamGreen 0:616601bde9fb 39 * Redistribution and use in source and binary forms are permitted
AdamGreen 0:616601bde9fb 40 * provided that the above copyright notice and this paragraph are
AdamGreen 0:616601bde9fb 41 * duplicated in all such forms and that any documentation,
AdamGreen 0:616601bde9fb 42 * advertising materials, and other materials related to such
AdamGreen 0:616601bde9fb 43 * distribution and use acknowledge that the software was developed
AdamGreen 0:616601bde9fb 44 * by Carnegie Mellon University. The name of the
AdamGreen 0:616601bde9fb 45 * University may not be used to endorse or promote products derived
AdamGreen 0:616601bde9fb 46 * from this software without specific prior written permission.
AdamGreen 0:616601bde9fb 47 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
AdamGreen 0:616601bde9fb 48 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
AdamGreen 0:616601bde9fb 49 * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
AdamGreen 0:616601bde9fb 50 *
AdamGreen 0:616601bde9fb 51 * $Id: ipcp.h,v 1.4 2010/01/18 20:49:43 goldsimon Exp $
AdamGreen 0:616601bde9fb 52 */
AdamGreen 0:616601bde9fb 53
AdamGreen 0:616601bde9fb 54 #ifndef IPCP_H
AdamGreen 0:616601bde9fb 55 #define IPCP_H
AdamGreen 0:616601bde9fb 56
AdamGreen 0:616601bde9fb 57 /*
AdamGreen 0:616601bde9fb 58 * Options.
AdamGreen 0:616601bde9fb 59 */
AdamGreen 0:616601bde9fb 60 #define CI_ADDRS 1 /* IP Addresses */
AdamGreen 0:616601bde9fb 61 #define CI_COMPRESSTYPE 2 /* Compression Type */
AdamGreen 0:616601bde9fb 62 #define CI_ADDR 3
AdamGreen 0:616601bde9fb 63
AdamGreen 0:616601bde9fb 64 #define CI_MS_DNS1 129 /* Primary DNS value */
AdamGreen 0:616601bde9fb 65 #define CI_MS_WINS1 128 /* Primary WINS value */
AdamGreen 0:616601bde9fb 66 #define CI_MS_DNS2 131 /* Secondary DNS value */
AdamGreen 0:616601bde9fb 67 #define CI_MS_WINS2 130 /* Secondary WINS value */
AdamGreen 0:616601bde9fb 68
AdamGreen 0:616601bde9fb 69 #define IPCP_VJMODE_OLD 1 /* "old" mode (option # = 0x0037) */
AdamGreen 0:616601bde9fb 70 #define IPCP_VJMODE_RFC1172 2 /* "old-rfc"mode (option # = 0x002d) */
AdamGreen 0:616601bde9fb 71 #define IPCP_VJMODE_RFC1332 3 /* "new-rfc"mode (option # = 0x002d, */
AdamGreen 0:616601bde9fb 72 /* maxslot and slot number compression) */
AdamGreen 0:616601bde9fb 73
AdamGreen 0:616601bde9fb 74 #define IPCP_VJ_COMP 0x002d /* current value for VJ compression option */
AdamGreen 0:616601bde9fb 75 #define IPCP_VJ_COMP_OLD 0x0037 /* "old" (i.e, broken) value for VJ */
AdamGreen 0:616601bde9fb 76 /* compression option */
AdamGreen 0:616601bde9fb 77
AdamGreen 0:616601bde9fb 78 typedef struct ipcp_options {
AdamGreen 0:616601bde9fb 79 u_int neg_addr : 1; /* Negotiate IP Address? */
AdamGreen 0:616601bde9fb 80 u_int old_addrs : 1; /* Use old (IP-Addresses) option? */
AdamGreen 0:616601bde9fb 81 u_int req_addr : 1; /* Ask peer to send IP address? */
AdamGreen 0:616601bde9fb 82 u_int default_route : 1; /* Assign default route through interface? */
AdamGreen 0:616601bde9fb 83 u_int proxy_arp : 1; /* Make proxy ARP entry for peer? */
AdamGreen 0:616601bde9fb 84 u_int neg_vj : 1; /* Van Jacobson Compression? */
AdamGreen 0:616601bde9fb 85 u_int old_vj : 1; /* use old (short) form of VJ option? */
AdamGreen 0:616601bde9fb 86 u_int accept_local : 1; /* accept peer's value for ouraddr */
AdamGreen 0:616601bde9fb 87 u_int accept_remote : 1; /* accept peer's value for hisaddr */
AdamGreen 0:616601bde9fb 88 u_int req_dns1 : 1; /* Ask peer to send primary DNS address? */
AdamGreen 0:616601bde9fb 89 u_int req_dns2 : 1; /* Ask peer to send secondary DNS address? */
AdamGreen 0:616601bde9fb 90 u_short vj_protocol; /* protocol value to use in VJ option */
AdamGreen 0:616601bde9fb 91 u_char maxslotindex; /* VJ slots - 1. */
AdamGreen 0:616601bde9fb 92 u_char cflag; /* VJ slot compression flag. */
AdamGreen 0:616601bde9fb 93 u32_t ouraddr, hisaddr; /* Addresses in NETWORK BYTE ORDER */
AdamGreen 0:616601bde9fb 94 u32_t dnsaddr[2]; /* Primary and secondary MS DNS entries */
AdamGreen 0:616601bde9fb 95 u32_t winsaddr[2]; /* Primary and secondary MS WINS entries */
AdamGreen 0:616601bde9fb 96 } ipcp_options;
AdamGreen 0:616601bde9fb 97
AdamGreen 0:616601bde9fb 98 extern fsm ipcp_fsm[];
AdamGreen 0:616601bde9fb 99 extern ipcp_options ipcp_wantoptions[];
AdamGreen 0:616601bde9fb 100 extern ipcp_options ipcp_gotoptions[];
AdamGreen 0:616601bde9fb 101 extern ipcp_options ipcp_allowoptions[];
AdamGreen 0:616601bde9fb 102 extern ipcp_options ipcp_hisoptions[];
AdamGreen 0:616601bde9fb 103
AdamGreen 0:616601bde9fb 104 extern struct protent ipcp_protent;
AdamGreen 0:616601bde9fb 105
AdamGreen 0:616601bde9fb 106 #endif /* IPCP_H */