Netservices modded to read fragmented HTTP respsonse/payload from special purpose server - 180 bytes only

Committer:
RodColeman
Date:
Thu Sep 08 10:48:09 2011 +0000
Revision:
0:850eacf3e945
revised fixed length to 178 bytes

Who changed what in which revision?

UserRevisionLine numberNew contents of line
RodColeman 0:850eacf3e945 1 /*
RodColeman 0:850eacf3e945 2 * Copyright (c) 2002 CITEL Technologies Ltd.
RodColeman 0:850eacf3e945 3 * All rights reserved.
RodColeman 0:850eacf3e945 4 *
RodColeman 0:850eacf3e945 5 * Redistribution and use in source and binary forms, with or without
RodColeman 0:850eacf3e945 6 * modification, are permitted provided that the following conditions
RodColeman 0:850eacf3e945 7 * are met:
RodColeman 0:850eacf3e945 8 * 1. Redistributions of source code must retain the above copyright
RodColeman 0:850eacf3e945 9 * notice, this list of conditions and the following disclaimer.
RodColeman 0:850eacf3e945 10 * 2. Redistributions in binary form must reproduce the above copyright
RodColeman 0:850eacf3e945 11 * notice, this list of conditions and the following disclaimer in the
RodColeman 0:850eacf3e945 12 * documentation and/or other materials provided with the distribution.
RodColeman 0:850eacf3e945 13 * 3. Neither the name of CITEL Technologies Ltd nor the names of its contributors
RodColeman 0:850eacf3e945 14 * may be used to endorse or promote products derived from this software
RodColeman 0:850eacf3e945 15 * without specific prior written permission.
RodColeman 0:850eacf3e945 16 *
RodColeman 0:850eacf3e945 17 * THIS SOFTWARE IS PROVIDED BY CITEL TECHNOLOGIES AND CONTRIBUTORS ``AS IS''
RodColeman 0:850eacf3e945 18 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
RodColeman 0:850eacf3e945 19 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
RodColeman 0:850eacf3e945 20 * ARE DISCLAIMED. IN NO EVENT SHALL CITEL TECHNOLOGIES OR CONTRIBUTORS BE LIABLE
RodColeman 0:850eacf3e945 21 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
RodColeman 0:850eacf3e945 22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
RodColeman 0:850eacf3e945 23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
RodColeman 0:850eacf3e945 24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
RodColeman 0:850eacf3e945 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
RodColeman 0:850eacf3e945 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
RodColeman 0:850eacf3e945 27 * SUCH DAMAGE.
RodColeman 0:850eacf3e945 28 *
RodColeman 0:850eacf3e945 29 * This file is a contribution to the lwIP TCP/IP stack.
RodColeman 0:850eacf3e945 30 * The Swedish Institute of Computer Science and Adam Dunkels
RodColeman 0:850eacf3e945 31 * are specifically granted permission to redistribute this
RodColeman 0:850eacf3e945 32 * source code.
RodColeman 0:850eacf3e945 33 */
RodColeman 0:850eacf3e945 34
RodColeman 0:850eacf3e945 35 #ifndef __LWIP_IGMP_H__
RodColeman 0:850eacf3e945 36 #define __LWIP_IGMP_H__
RodColeman 0:850eacf3e945 37
RodColeman 0:850eacf3e945 38 #include "lwip/opt.h"
RodColeman 0:850eacf3e945 39 #include "lwip/ip_addr.h"
RodColeman 0:850eacf3e945 40 #include "lwip/netif.h"
RodColeman 0:850eacf3e945 41 #include "lwip/pbuf.h"
RodColeman 0:850eacf3e945 42
RodColeman 0:850eacf3e945 43 #if LWIP_IGMP /* don't build if not configured for use in lwipopts.h */
RodColeman 0:850eacf3e945 44
RodColeman 0:850eacf3e945 45 #ifdef __cplusplus
RodColeman 0:850eacf3e945 46 extern "C" {
RodColeman 0:850eacf3e945 47 #endif
RodColeman 0:850eacf3e945 48
RodColeman 0:850eacf3e945 49
RodColeman 0:850eacf3e945 50 /* IGMP timer */
RodColeman 0:850eacf3e945 51 #define IGMP_TMR_INTERVAL 100 /* Milliseconds */
RodColeman 0:850eacf3e945 52 #define IGMP_V1_DELAYING_MEMBER_TMR (1000/IGMP_TMR_INTERVAL)
RodColeman 0:850eacf3e945 53 #define IGMP_JOIN_DELAYING_MEMBER_TMR (500 /IGMP_TMR_INTERVAL)
RodColeman 0:850eacf3e945 54
RodColeman 0:850eacf3e945 55 /* MAC Filter Actions, these are passed to a netif's
RodColeman 0:850eacf3e945 56 * igmp_mac_filter callback function. */
RodColeman 0:850eacf3e945 57 #define IGMP_DEL_MAC_FILTER 0
RodColeman 0:850eacf3e945 58 #define IGMP_ADD_MAC_FILTER 1
RodColeman 0:850eacf3e945 59
RodColeman 0:850eacf3e945 60
RodColeman 0:850eacf3e945 61 /**
RodColeman 0:850eacf3e945 62 * igmp group structure - there is
RodColeman 0:850eacf3e945 63 * a list of groups for each interface
RodColeman 0:850eacf3e945 64 * these should really be linked from the interface, but
RodColeman 0:850eacf3e945 65 * if we keep them separate we will not affect the lwip original code
RodColeman 0:850eacf3e945 66 * too much
RodColeman 0:850eacf3e945 67 *
RodColeman 0:850eacf3e945 68 * There will be a group for the all systems group address but this
RodColeman 0:850eacf3e945 69 * will not run the state machine as it is used to kick off reports
RodColeman 0:850eacf3e945 70 * from all the other groups
RodColeman 0:850eacf3e945 71 */
RodColeman 0:850eacf3e945 72 struct igmp_group {
RodColeman 0:850eacf3e945 73 /** next link */
RodColeman 0:850eacf3e945 74 struct igmp_group *next;
RodColeman 0:850eacf3e945 75 /** interface on which the group is active */
RodColeman 0:850eacf3e945 76 struct netif *netif;
RodColeman 0:850eacf3e945 77 /** multicast address */
RodColeman 0:850eacf3e945 78 ip_addr_t group_address;
RodColeman 0:850eacf3e945 79 /** signifies we were the last person to report */
RodColeman 0:850eacf3e945 80 u8_t last_reporter_flag;
RodColeman 0:850eacf3e945 81 /** current state of the group */
RodColeman 0:850eacf3e945 82 u8_t group_state;
RodColeman 0:850eacf3e945 83 /** timer for reporting, negative is OFF */
RodColeman 0:850eacf3e945 84 u16_t timer;
RodColeman 0:850eacf3e945 85 /** counter of simultaneous uses */
RodColeman 0:850eacf3e945 86 u8_t use;
RodColeman 0:850eacf3e945 87 };
RodColeman 0:850eacf3e945 88
RodColeman 0:850eacf3e945 89 /* Prototypes */
RodColeman 0:850eacf3e945 90 void igmp_init(void);
RodColeman 0:850eacf3e945 91 err_t igmp_start(struct netif *netif);
RodColeman 0:850eacf3e945 92 err_t igmp_stop(struct netif *netif);
RodColeman 0:850eacf3e945 93 void igmp_report_groups(struct netif *netif);
RodColeman 0:850eacf3e945 94 struct igmp_group *igmp_lookfor_group(struct netif *ifp, ip_addr_t *addr);
RodColeman 0:850eacf3e945 95 void igmp_input(struct pbuf *p, struct netif *inp, ip_addr_t *dest);
RodColeman 0:850eacf3e945 96 err_t igmp_joingroup(ip_addr_t *ifaddr, ip_addr_t *groupaddr);
RodColeman 0:850eacf3e945 97 err_t igmp_leavegroup(ip_addr_t *ifaddr, ip_addr_t *groupaddr);
RodColeman 0:850eacf3e945 98 void igmp_tmr(void);
RodColeman 0:850eacf3e945 99
RodColeman 0:850eacf3e945 100 #ifdef __cplusplus
RodColeman 0:850eacf3e945 101 }
RodColeman 0:850eacf3e945 102 #endif
RodColeman 0:850eacf3e945 103
RodColeman 0:850eacf3e945 104 #endif /* LWIP_IGMP */
RodColeman 0:850eacf3e945 105
RodColeman 0:850eacf3e945 106 #endif /* __LWIP_IGMP_H__ */