Integrating the ublox LISA C200 modem

Fork of SprintUSBModemHTTPClientTest by Donatien Garnier

Committer:
sam_grove
Date:
Thu Sep 26 00:44:20 2013 -0500
Revision:
5:3f93dd1d4cb3
Exported program and replaced contents of the repo with the source
to build and debug using keil mdk. Libs NOT upto date are lwip, lwip-sys
and socket. these have newer versions under mbed_official but were starting
from a know working point

Who changed what in which revision?

UserRevisionLine numberNew contents of line
sam_grove 5:3f93dd1d4cb3 1 /*
sam_grove 5:3f93dd1d4cb3 2 * Copyright (c) 2001-2004 Swedish Institute of Computer Science.
sam_grove 5:3f93dd1d4cb3 3 * All rights reserved.
sam_grove 5:3f93dd1d4cb3 4 *
sam_grove 5:3f93dd1d4cb3 5 * Redistribution and use in source and binary forms, with or without modification,
sam_grove 5:3f93dd1d4cb3 6 * are permitted provided that the following conditions are met:
sam_grove 5:3f93dd1d4cb3 7 *
sam_grove 5:3f93dd1d4cb3 8 * 1. Redistributions of source code must retain the above copyright notice,
sam_grove 5:3f93dd1d4cb3 9 * this list of conditions and the following disclaimer.
sam_grove 5:3f93dd1d4cb3 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
sam_grove 5:3f93dd1d4cb3 11 * this list of conditions and the following disclaimer in the documentation
sam_grove 5:3f93dd1d4cb3 12 * and/or other materials provided with the distribution.
sam_grove 5:3f93dd1d4cb3 13 * 3. The name of the author may not be used to endorse or promote products
sam_grove 5:3f93dd1d4cb3 14 * derived from this software without specific prior written permission.
sam_grove 5:3f93dd1d4cb3 15 *
sam_grove 5:3f93dd1d4cb3 16 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
sam_grove 5:3f93dd1d4cb3 17 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
sam_grove 5:3f93dd1d4cb3 18 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT
sam_grove 5:3f93dd1d4cb3 19 * SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
sam_grove 5:3f93dd1d4cb3 20 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
sam_grove 5:3f93dd1d4cb3 21 * OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
sam_grove 5:3f93dd1d4cb3 22 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
sam_grove 5:3f93dd1d4cb3 23 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
sam_grove 5:3f93dd1d4cb3 24 * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
sam_grove 5:3f93dd1d4cb3 25 * OF SUCH DAMAGE.
sam_grove 5:3f93dd1d4cb3 26 *
sam_grove 5:3f93dd1d4cb3 27 * This file is part of the lwIP TCP/IP stack.
sam_grove 5:3f93dd1d4cb3 28 *
sam_grove 5:3f93dd1d4cb3 29 * Author: Adam Dunkels <adam@sics.se>
sam_grove 5:3f93dd1d4cb3 30 *
sam_grove 5:3f93dd1d4cb3 31 */
sam_grove 5:3f93dd1d4cb3 32 #ifndef __LWIP_DEBUG_H__
sam_grove 5:3f93dd1d4cb3 33 #define __LWIP_DEBUG_H__
sam_grove 5:3f93dd1d4cb3 34
sam_grove 5:3f93dd1d4cb3 35 #include "lwip/arch.h"
sam_grove 5:3f93dd1d4cb3 36
sam_grove 5:3f93dd1d4cb3 37 /** lower two bits indicate debug level
sam_grove 5:3f93dd1d4cb3 38 * - 0 all
sam_grove 5:3f93dd1d4cb3 39 * - 1 warning
sam_grove 5:3f93dd1d4cb3 40 * - 2 serious
sam_grove 5:3f93dd1d4cb3 41 * - 3 severe
sam_grove 5:3f93dd1d4cb3 42 */
sam_grove 5:3f93dd1d4cb3 43 #define LWIP_DBG_LEVEL_ALL 0x00
sam_grove 5:3f93dd1d4cb3 44 #define LWIP_DBG_LEVEL_OFF LWIP_DBG_LEVEL_ALL /* compatibility define only */
sam_grove 5:3f93dd1d4cb3 45 #define LWIP_DBG_LEVEL_WARNING 0x01 /* bad checksums, dropped packets, ... */
sam_grove 5:3f93dd1d4cb3 46 #define LWIP_DBG_LEVEL_SERIOUS 0x02 /* memory allocation failures, ... */
sam_grove 5:3f93dd1d4cb3 47 #define LWIP_DBG_LEVEL_SEVERE 0x03
sam_grove 5:3f93dd1d4cb3 48 #define LWIP_DBG_MASK_LEVEL 0x03
sam_grove 5:3f93dd1d4cb3 49
sam_grove 5:3f93dd1d4cb3 50 /** flag for LWIP_DEBUGF to enable that debug message */
sam_grove 5:3f93dd1d4cb3 51 #define LWIP_DBG_ON 0x80U
sam_grove 5:3f93dd1d4cb3 52 /** flag for LWIP_DEBUGF to disable that debug message */
sam_grove 5:3f93dd1d4cb3 53 #define LWIP_DBG_OFF 0x00U
sam_grove 5:3f93dd1d4cb3 54
sam_grove 5:3f93dd1d4cb3 55 /** flag for LWIP_DEBUGF indicating a tracing message (to follow program flow) */
sam_grove 5:3f93dd1d4cb3 56 #define LWIP_DBG_TRACE 0x40U
sam_grove 5:3f93dd1d4cb3 57 /** flag for LWIP_DEBUGF indicating a state debug message (to follow module states) */
sam_grove 5:3f93dd1d4cb3 58 #define LWIP_DBG_STATE 0x20U
sam_grove 5:3f93dd1d4cb3 59 /** flag for LWIP_DEBUGF indicating newly added code, not thoroughly tested yet */
sam_grove 5:3f93dd1d4cb3 60 #define LWIP_DBG_FRESH 0x10U
sam_grove 5:3f93dd1d4cb3 61 /** flag for LWIP_DEBUGF to halt after printing this debug message */
sam_grove 5:3f93dd1d4cb3 62 #define LWIP_DBG_HALT 0x08U
sam_grove 5:3f93dd1d4cb3 63
sam_grove 5:3f93dd1d4cb3 64 #ifndef LWIP_NOASSERT
sam_grove 5:3f93dd1d4cb3 65 #define LWIP_ASSERT(message, assertion) do { if(!(assertion)) \
sam_grove 5:3f93dd1d4cb3 66 LWIP_PLATFORM_ASSERT(message); } while(0)
sam_grove 5:3f93dd1d4cb3 67 #else /* LWIP_NOASSERT */
sam_grove 5:3f93dd1d4cb3 68 #define LWIP_ASSERT(message, assertion)
sam_grove 5:3f93dd1d4cb3 69 #endif /* LWIP_NOASSERT */
sam_grove 5:3f93dd1d4cb3 70
sam_grove 5:3f93dd1d4cb3 71 /** if "expression" isn't true, then print "message" and execute "handler" expression */
sam_grove 5:3f93dd1d4cb3 72 #ifndef LWIP_ERROR
sam_grove 5:3f93dd1d4cb3 73 #define LWIP_ERROR(message, expression, handler) do { if (!(expression)) { \
sam_grove 5:3f93dd1d4cb3 74 LWIP_PLATFORM_ASSERT(message); handler;}} while(0)
sam_grove 5:3f93dd1d4cb3 75 #endif /* LWIP_ERROR */
sam_grove 5:3f93dd1d4cb3 76
sam_grove 5:3f93dd1d4cb3 77 #ifdef LWIP_DEBUG
sam_grove 5:3f93dd1d4cb3 78 /** print debug message only if debug message type is enabled...
sam_grove 5:3f93dd1d4cb3 79 * AND is of correct type AND is at least LWIP_DBG_LEVEL
sam_grove 5:3f93dd1d4cb3 80 */
sam_grove 5:3f93dd1d4cb3 81 #define LWIP_DEBUGF(debug, message) do { \
sam_grove 5:3f93dd1d4cb3 82 if ( \
sam_grove 5:3f93dd1d4cb3 83 ((debug) & LWIP_DBG_ON) && \
sam_grove 5:3f93dd1d4cb3 84 ((debug) & LWIP_DBG_TYPES_ON) && \
sam_grove 5:3f93dd1d4cb3 85 ((s16_t)((debug) & LWIP_DBG_MASK_LEVEL) >= LWIP_DBG_MIN_LEVEL)) { \
sam_grove 5:3f93dd1d4cb3 86 LWIP_PLATFORM_DIAG(message); \
sam_grove 5:3f93dd1d4cb3 87 if ((debug) & LWIP_DBG_HALT) { \
sam_grove 5:3f93dd1d4cb3 88 while(1); \
sam_grove 5:3f93dd1d4cb3 89 } \
sam_grove 5:3f93dd1d4cb3 90 } \
sam_grove 5:3f93dd1d4cb3 91 } while(0)
sam_grove 5:3f93dd1d4cb3 92
sam_grove 5:3f93dd1d4cb3 93 #else /* LWIP_DEBUG */
sam_grove 5:3f93dd1d4cb3 94 #define LWIP_DEBUGF(debug, message)
sam_grove 5:3f93dd1d4cb3 95 #endif /* LWIP_DEBUG */
sam_grove 5:3f93dd1d4cb3 96
sam_grove 5:3f93dd1d4cb3 97 #endif /* __LWIP_DEBUG_H__ */
sam_grove 5:3f93dd1d4cb3 98