Implementation of 3G USB Modem Huawei E372

Dependents:   PYRN

Committer:
clemounet
Date:
Tue Apr 14 13:27:07 2015 +0000
Revision:
2:61ac95f0af72
.up (working)

Who changed what in which revision?

UserRevisionLine numberNew contents of line
clemounet 2:61ac95f0af72 1 /* fwk.h */
clemounet 2:61ac95f0af72 2 /* Copyright (C) 2012 mbed.org, MIT License
clemounet 2:61ac95f0af72 3 *
clemounet 2:61ac95f0af72 4 * Permission is hereby granted, free of charge, to any person obtaining a copy of this software
clemounet 2:61ac95f0af72 5 * and associated documentation files (the "Software"), to deal in the Software without restriction,
clemounet 2:61ac95f0af72 6 * including without limitation the rights to use, copy, modify, merge, publish, distribute,
clemounet 2:61ac95f0af72 7 * sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
clemounet 2:61ac95f0af72 8 * furnished to do so, subject to the following conditions:
clemounet 2:61ac95f0af72 9 *
clemounet 2:61ac95f0af72 10 * The above copyright notice and this permission notice shall be included in all copies or
clemounet 2:61ac95f0af72 11 * substantial portions of the Software.
clemounet 2:61ac95f0af72 12 *
clemounet 2:61ac95f0af72 13 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
clemounet 2:61ac95f0af72 14 * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
clemounet 2:61ac95f0af72 15 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
clemounet 2:61ac95f0af72 16 * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
clemounet 2:61ac95f0af72 17 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
clemounet 2:61ac95f0af72 18 */
clemounet 2:61ac95f0af72 19
clemounet 2:61ac95f0af72 20 #ifndef FWK_H_
clemounet 2:61ac95f0af72 21 #define FWK_H_
clemounet 2:61ac95f0af72 22
clemounet 2:61ac95f0af72 23 #include "config.h"
clemounet 2:61ac95f0af72 24
clemounet 2:61ac95f0af72 25 #include "string.h"
clemounet 2:61ac95f0af72 26 //using namespace std;
clemounet 2:61ac95f0af72 27
clemounet 2:61ac95f0af72 28 #include "stdint.h"
clemounet 2:61ac95f0af72 29 typedef unsigned int size_t;
clemounet 2:61ac95f0af72 30
clemounet 2:61ac95f0af72 31 #ifndef __cplusplus
clemounet 2:61ac95f0af72 32 //boolean type compatibility
clemounet 2:61ac95f0af72 33 typedef byte bool;
clemounet 2:61ac95f0af72 34 #define true 1
clemounet 2:61ac95f0af72 35 #define false 0
clemounet 2:61ac95f0af72 36 #endif
clemounet 2:61ac95f0af72 37
clemounet 2:61ac95f0af72 38 #ifndef NULL
clemounet 2:61ac95f0af72 39 #define NULL ((void*)0)
clemounet 2:61ac95f0af72 40 #endif
clemounet 2:61ac95f0af72 41
clemounet 2:61ac95f0af72 42 #define CR '\x0D'
clemounet 2:61ac95f0af72 43 #define LF '\x0A'
clemounet 2:61ac95f0af72 44 #define GD '\x3E'
clemounet 2:61ac95f0af72 45 #define BRK '\x1A'
clemounet 2:61ac95f0af72 46
clemounet 2:61ac95f0af72 47 //Custom utility classes
clemounet 2:61ac95f0af72 48 #include "IOStream.h"
clemounet 2:61ac95f0af72 49 //#include "String.h"
clemounet 2:61ac95f0af72 50
clemounet 2:61ac95f0af72 51 //Error codes
clemounet 2:61ac95f0af72 52 #include "errors.h"
clemounet 2:61ac95f0af72 53
clemounet 2:61ac95f0af72 54 //Utility macros
clemounet 2:61ac95f0af72 55 #define MIN(x,y) (((x)<(y))?(x):(y))
clemounet 2:61ac95f0af72 56 #define MAX(x,y) (((x)>(y))?(x):(y))
clemounet 2:61ac95f0af72 57
clemounet 2:61ac95f0af72 58 #endif /* FWK_H_ */