Hi. This is the feed program for Cosm. (The previous name of the services is Pachube.)

Dependencies:   mbed ThermistorPack Pachube ConfigFile EthernetNetIf TextLCD HTTPClient_ToBeRemoved FatFileSystem SDFileSystem

Committer:
shintamainjp
Date:
Mon Aug 06 12:37:59 2012 +0000
Revision:
0:521ba375aa0f
Pachube renamed to Cosm.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
shintamainjp 0:521ba375aa0f 1 /*
shintamainjp 0:521ba375aa0f 2 * Copyright (c) 2001-2004 Swedish Institute of Computer Science.
shintamainjp 0:521ba375aa0f 3 * All rights reserved.
shintamainjp 0:521ba375aa0f 4 *
shintamainjp 0:521ba375aa0f 5 * Redistribution and use in source and binary forms, with or without modification,
shintamainjp 0:521ba375aa0f 6 * are permitted provided that the following conditions are met:
shintamainjp 0:521ba375aa0f 7 *
shintamainjp 0:521ba375aa0f 8 * 1. Redistributions of source code must retain the above copyright notice,
shintamainjp 0:521ba375aa0f 9 * this list of conditions and the following disclaimer.
shintamainjp 0:521ba375aa0f 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
shintamainjp 0:521ba375aa0f 11 * this list of conditions and the following disclaimer in the documentation
shintamainjp 0:521ba375aa0f 12 * and/or other materials provided with the distribution.
shintamainjp 0:521ba375aa0f 13 * 3. The name of the author may not be used to endorse or promote products
shintamainjp 0:521ba375aa0f 14 * derived from this software without specific prior written permission.
shintamainjp 0:521ba375aa0f 15 *
shintamainjp 0:521ba375aa0f 16 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
shintamainjp 0:521ba375aa0f 17 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
shintamainjp 0:521ba375aa0f 18 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT
shintamainjp 0:521ba375aa0f 19 * SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
shintamainjp 0:521ba375aa0f 20 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
shintamainjp 0:521ba375aa0f 21 * OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
shintamainjp 0:521ba375aa0f 22 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
shintamainjp 0:521ba375aa0f 23 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
shintamainjp 0:521ba375aa0f 24 * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
shintamainjp 0:521ba375aa0f 25 * OF SUCH DAMAGE.
shintamainjp 0:521ba375aa0f 26 *
shintamainjp 0:521ba375aa0f 27 * This file is part of the lwIP TCP/IP stack.
shintamainjp 0:521ba375aa0f 28 *
shintamainjp 0:521ba375aa0f 29 * Author: Adam Dunkels <adam@sics.se>
shintamainjp 0:521ba375aa0f 30 *
shintamainjp 0:521ba375aa0f 31 */
shintamainjp 0:521ba375aa0f 32 #ifndef __LWIP_RAW_H__
shintamainjp 0:521ba375aa0f 33 #define __LWIP_RAW_H__
shintamainjp 0:521ba375aa0f 34
shintamainjp 0:521ba375aa0f 35 #include "lwip/opt.h"
shintamainjp 0:521ba375aa0f 36
shintamainjp 0:521ba375aa0f 37 #if LWIP_RAW /* don't build if not configured for use in lwipopts.h */
shintamainjp 0:521ba375aa0f 38
shintamainjp 0:521ba375aa0f 39 #include "lwip/pbuf.h"
shintamainjp 0:521ba375aa0f 40 #include "lwip/def.h"
shintamainjp 0:521ba375aa0f 41 #include "lwip/ip.h"
shintamainjp 0:521ba375aa0f 42 #include "lwip/ip_addr.h"
shintamainjp 0:521ba375aa0f 43
shintamainjp 0:521ba375aa0f 44 #ifdef __cplusplus
shintamainjp 0:521ba375aa0f 45 extern "C" {
shintamainjp 0:521ba375aa0f 46 #endif
shintamainjp 0:521ba375aa0f 47
shintamainjp 0:521ba375aa0f 48 struct raw_pcb;
shintamainjp 0:521ba375aa0f 49
shintamainjp 0:521ba375aa0f 50 /** Function prototype for raw pcb receive callback functions.
shintamainjp 0:521ba375aa0f 51 * @param arg user supplied argument (raw_pcb.recv_arg)
shintamainjp 0:521ba375aa0f 52 * @param pcb the raw_pcb which received data
shintamainjp 0:521ba375aa0f 53 * @param p the packet buffer that was received
shintamainjp 0:521ba375aa0f 54 * @param addr the remote IP address from which the packet was received
shintamainjp 0:521ba375aa0f 55 * @return 1 if the packet was 'eaten' (aka. deleted),
shintamainjp 0:521ba375aa0f 56 * 0 if the packet lives on
shintamainjp 0:521ba375aa0f 57 * If returning 1, the callback is responsible for freeing the pbuf
shintamainjp 0:521ba375aa0f 58 * if it's not used any more.
shintamainjp 0:521ba375aa0f 59 */
shintamainjp 0:521ba375aa0f 60 typedef u8_t (*raw_recv_fn)(void *arg, struct raw_pcb *pcb, struct pbuf *p,
shintamainjp 0:521ba375aa0f 61 ip_addr_t *addr);
shintamainjp 0:521ba375aa0f 62
shintamainjp 0:521ba375aa0f 63 struct raw_pcb {
shintamainjp 0:521ba375aa0f 64 /* Common members of all PCB types */
shintamainjp 0:521ba375aa0f 65 IP_PCB;
shintamainjp 0:521ba375aa0f 66
shintamainjp 0:521ba375aa0f 67 struct raw_pcb *next;
shintamainjp 0:521ba375aa0f 68
shintamainjp 0:521ba375aa0f 69 u8_t protocol;
shintamainjp 0:521ba375aa0f 70
shintamainjp 0:521ba375aa0f 71 /** receive callback function */
shintamainjp 0:521ba375aa0f 72 raw_recv_fn recv;
shintamainjp 0:521ba375aa0f 73 /* user-supplied argument for the recv callback */
shintamainjp 0:521ba375aa0f 74 void *recv_arg;
shintamainjp 0:521ba375aa0f 75 };
shintamainjp 0:521ba375aa0f 76
shintamainjp 0:521ba375aa0f 77 /* The following functions is the application layer interface to the
shintamainjp 0:521ba375aa0f 78 RAW code. */
shintamainjp 0:521ba375aa0f 79 struct raw_pcb * raw_new (u8_t proto);
shintamainjp 0:521ba375aa0f 80 void raw_remove (struct raw_pcb *pcb);
shintamainjp 0:521ba375aa0f 81 err_t raw_bind (struct raw_pcb *pcb, ip_addr_t *ipaddr);
shintamainjp 0:521ba375aa0f 82 err_t raw_connect (struct raw_pcb *pcb, ip_addr_t *ipaddr);
shintamainjp 0:521ba375aa0f 83
shintamainjp 0:521ba375aa0f 84 void raw_recv (struct raw_pcb *pcb, raw_recv_fn recv, void *recv_arg);
shintamainjp 0:521ba375aa0f 85 err_t raw_sendto (struct raw_pcb *pcb, struct pbuf *p, ip_addr_t *ipaddr);
shintamainjp 0:521ba375aa0f 86 err_t raw_send (struct raw_pcb *pcb, struct pbuf *p);
shintamainjp 0:521ba375aa0f 87
shintamainjp 0:521ba375aa0f 88 /* The following functions are the lower layer interface to RAW. */
shintamainjp 0:521ba375aa0f 89 u8_t raw_input (struct pbuf *p, struct netif *inp);
shintamainjp 0:521ba375aa0f 90 #define raw_init() /* Compatibility define, not init needed. */
shintamainjp 0:521ba375aa0f 91
shintamainjp 0:521ba375aa0f 92 #ifdef __cplusplus
shintamainjp 0:521ba375aa0f 93 }
shintamainjp 0:521ba375aa0f 94 #endif
shintamainjp 0:521ba375aa0f 95
shintamainjp 0:521ba375aa0f 96 #endif /* LWIP_RAW */
shintamainjp 0:521ba375aa0f 97
shintamainjp 0:521ba375aa0f 98 #endif /* __LWIP_RAW_H__ */