![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
a
Dependencies: HMC6352 PID mbed
Diff: uart1.h
- Revision:
- 0:8215f0743d86
diff -r 000000000000 -r 8215f0743d86 uart1.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/uart1.h Fri Apr 19 09:13:32 2013 +0000 @@ -0,0 +1,35 @@ + + + +#define RECEIVE_DATA_NUM 13 +#define SEND_DATA_NUM 6 + +#define KEYCODE 120 +#define CHECKCODE (RecData[DIRECTION] ^ RecData[DISTANCE] ^ RecData[SONIC1_1] ^ RecData[SONIC1_2] ^ RecData[SONIC2_1] ^ RecData[SONIC2_2] ^ RecData[SONIC3_1] ^ RecData[SONIC3_2] ^ RecData[SONIC4_1] ^ RecData[SONIC4_2] ^ RecData[XBEE]) +#define KEYCODE2 35 +#define CHECKCODE2 (SendData[DATA1] ^ SendData[DATA2] ^ SendData[DATA3] ^ SendData[DATA4]) + + +enum{ + KEY = 0, + DIRECTION, + DISTANCE, + SONIC1_1, + SONIC1_2, + SONIC2_1, + SONIC2_2, + SONIC3_1, + SONIC3_2, + SONIC4_1, + SONIC4_2, + XBEE, + CHECK, +}; +enum{ + KEY2 = 0, + DATA1, + DATA2, + DATA3, + DATA4, + CHECK2, +};