Xbee API Test 3

Dependencies:   XBee mbed

> help
h or help
m <status-in-hex>,. ... Modem status
l <cmd>,<val-in-hex>.   ... exec <cmd> (AT) at this host.
lset fid <val-in-hex>. ... set local frame id. default is 1.
lset cmd <val-in-hex>. ... set local command.
lset val <val-in-hex>. ... set local command value.
q <cmd>,<val-in-hex>.   ... set queue parameter value.
r <cmd>,<val-in-hex>.   ... exec <cmd> (AT)at remote host.
rset a16 <val-in-hex>. ... set remote address high.
rset a64 <val-in-hex>,<val-in-hex>.  ... set remote address low.
rset fid <val-in-hex>. ... set remote frame id. default is 1.

> l D4,0x05
cmd=D4 val=0x05
apiId=88

object 100008c8:35 01 00 10 88 00 05 FE 04 01 00 FF

l OK:

> l D4,0x04
cmd=D4 val=0x04
apiId=88

object 100008c8:35 01 00 10 88 00 05 FE 04 01 00 FF

l OK:

>
Committer:
takashiyamanoue
Date:
Sat Jul 21 04:09:54 2012 +0000
Revision:
0:3edcfa3aba71
xbee test 3

Who changed what in which revision?

UserRevisionLine numberNew contents of line
takashiyamanoue 0:3edcfa3aba71 1 /*
takashiyamanoue 0:3edcfa3aba71 2 * Author: Adam Dunkels <adam@sics.se>
takashiyamanoue 0:3edcfa3aba71 3 *
takashiyamanoue 0:3edcfa3aba71 4 */
takashiyamanoue 0:3edcfa3aba71 5 #ifndef __LWIP_ARCH_CC_H__
takashiyamanoue 0:3edcfa3aba71 6 #define __LWIP_ARCH_CC_H__
takashiyamanoue 0:3edcfa3aba71 7
takashiyamanoue 0:3edcfa3aba71 8 #define LITTLE_ENDIAN 1234
takashiyamanoue 0:3edcfa3aba71 9
takashiyamanoue 0:3edcfa3aba71 10 #define BYTE_ORDER LITTLE_ENDIAN
takashiyamanoue 0:3edcfa3aba71 11
takashiyamanoue 0:3edcfa3aba71 12 typedef unsigned char u8_t;
takashiyamanoue 0:3edcfa3aba71 13 typedef signed char s8_t;
takashiyamanoue 0:3edcfa3aba71 14 typedef unsigned short u16_t;
takashiyamanoue 0:3edcfa3aba71 15 typedef signed short s16_t;
takashiyamanoue 0:3edcfa3aba71 16 typedef unsigned int u32_t;
takashiyamanoue 0:3edcfa3aba71 17 typedef signed int s32_t;
takashiyamanoue 0:3edcfa3aba71 18 typedef unsigned int mem_ptr_t;
takashiyamanoue 0:3edcfa3aba71 19
takashiyamanoue 0:3edcfa3aba71 20 #ifndef NULL
takashiyamanoue 0:3edcfa3aba71 21 #define NULL 0
takashiyamanoue 0:3edcfa3aba71 22 #endif
takashiyamanoue 0:3edcfa3aba71 23
takashiyamanoue 0:3edcfa3aba71 24 #ifndef TRUE
takashiyamanoue 0:3edcfa3aba71 25 #define TRUE 1
takashiyamanoue 0:3edcfa3aba71 26 #endif
takashiyamanoue 0:3edcfa3aba71 27
takashiyamanoue 0:3edcfa3aba71 28 #ifndef FALSE
takashiyamanoue 0:3edcfa3aba71 29 #define FALSE 0
takashiyamanoue 0:3edcfa3aba71 30 #endif
takashiyamanoue 0:3edcfa3aba71 31
takashiyamanoue 0:3edcfa3aba71 32 #include <stdlib.h>
takashiyamanoue 0:3edcfa3aba71 33 #define LWIP_RAND rand
takashiyamanoue 0:3edcfa3aba71 34
takashiyamanoue 0:3edcfa3aba71 35 #define LWIP_PLATFORM_DIAG(x) DBG x
takashiyamanoue 0:3edcfa3aba71 36 #define LWIP_PLATFORM_ASSERT(x) DBG(x)
takashiyamanoue 0:3edcfa3aba71 37
takashiyamanoue 0:3edcfa3aba71 38 #define LWIP_PROVIDE_ERRNO
takashiyamanoue 0:3edcfa3aba71 39
takashiyamanoue 0:3edcfa3aba71 40 #define U16_F "hu"
takashiyamanoue 0:3edcfa3aba71 41 #define S16_F "hd"
takashiyamanoue 0:3edcfa3aba71 42 #define X16_F "hx"
takashiyamanoue 0:3edcfa3aba71 43 #define U32_F "lu"
takashiyamanoue 0:3edcfa3aba71 44 #define S32_F "ld"
takashiyamanoue 0:3edcfa3aba71 45 #define X32_F "lx"
takashiyamanoue 0:3edcfa3aba71 46
takashiyamanoue 0:3edcfa3aba71 47 #if 0
takashiyamanoue 0:3edcfa3aba71 48 /*Create compilation problems, and according to http://www.mail-archive.com/lwip-users@nongnu.org/msg06786.html,
takashiyamanoue 0:3edcfa3aba71 49 lwIP uses packed structures, so packing the field is not really a good idea ;) */
takashiyamanoue 0:3edcfa3aba71 50 #define PACK_STRUCT_FIELD(x) __packed x
takashiyamanoue 0:3edcfa3aba71 51 #else
takashiyamanoue 0:3edcfa3aba71 52 #define PACK_STRUCT_FIELD(x) x
takashiyamanoue 0:3edcfa3aba71 53 #endif
takashiyamanoue 0:3edcfa3aba71 54
takashiyamanoue 0:3edcfa3aba71 55 #define PACK_STRUCT_STRUCT
takashiyamanoue 0:3edcfa3aba71 56 #define PACK_STRUCT_BEGIN __packed
takashiyamanoue 0:3edcfa3aba71 57 #define PACK_STRUCT_END
takashiyamanoue 0:3edcfa3aba71 58
takashiyamanoue 0:3edcfa3aba71 59 #define LWIP_CHKSUM_ALGORITHM 3
takashiyamanoue 0:3edcfa3aba71 60
takashiyamanoue 0:3edcfa3aba71 61
takashiyamanoue 0:3edcfa3aba71 62 #endif /* __LWIP_ARCH_CC_H__ */