gyo

Committer:
nanjo
Date:
Sat Feb 16 07:24:19 2019 +0000
Revision:
9:8538fc8f6259
Parent:
8:f3e2b37e206f
Child:
12:f7eb7dfa1356
test;

Who changed what in which revision?

UserRevisionLine numberNew contents of line
gotto0 1:8810976be033 1 #ifndef INCLDUED_SBDBT_h_
gotto0 1:8810976be033 2 #define INCLDUED_SBDBT_h_
gotto0 0:afe58893bfe7 3 #include "mbed.h"
gotto0 0:afe58893bfe7 4
gotto0 7:30e05998769b 5 //data[1]
gotto0 8:f3e2b37e206f 6 #define SHIKAKU_ 0x01
gotto0 8:f3e2b37e206f 7 #define L1_ 0x02
gotto0 8:f3e2b37e206f 8 #define L2_ 0x04
nanjo 9:8538fc8f6259 9 #define L3_ 0x08
nanjo 9:8538fc8f6259 10 #define R1_ 0x10
nanjo 9:8538fc8f6259 11 #define R2_ 0x20
nanjo 9:8538fc8f6259 12 #define R3_ 0x40
gotto0 7:30e05998769b 13
gotto0 7:30e05998769b 14 //data[2]
gotto0 8:f3e2b37e206f 15 #define UE_ 0x01
gotto0 8:f3e2b37e206f 16 #define SITA_ 0x02
gotto0 8:f3e2b37e206f 17 #define MIGI_ 0x04
gotto0 8:f3e2b37e206f 18 #define HIDARI_ 0x08
gotto0 8:f3e2b37e206f 19 #define SANKAKU_ 0x10
gotto0 8:f3e2b37e206f 20 #define BATU_ 0x20
gotto0 8:f3e2b37e206f 21 #define MARU_ 0x40
gotto0 8:f3e2b37e206f 22 #define START_ 3
gotto0 8:f3e2b37e206f 23 #define SELECT_ 12
gotto0 6:da71294502ee 24
nanjo 9:8538fc8f6259 25
gotto0 0:afe58893bfe7 26 class SBDBT
gotto0 0:afe58893bfe7 27 {
gotto0 0:afe58893bfe7 28 private:
gotto0 0:afe58893bfe7 29 char i;
gotto0 1:8810976be033 30 char length;
gotto0 1:8810976be033 31 char value;
gotto0 1:8810976be033 32 char position;
gotto0 2:1472e7c5317d 33 char *tmp;
gotto0 2:1472e7c5317d 34 Serial *sr;
gotto0 0:afe58893bfe7 35
gotto0 0:afe58893bfe7 36 public:
gotto0 4:3f384ebf4509 37 char readable;
gotto0 1:8810976be033 38 char *data;
gotto0 6:da71294502ee 39 char *data_p;
gotto0 0:afe58893bfe7 40 SBDBT(PinName, PinName);
gotto0 1:8810976be033 41 SBDBT(PinName, PinName, int);
gotto0 1:8810976be033 42 void getf();
gotto0 6:da71294502ee 43 void print();
nanjo 9:8538fc8f6259 44 int8_t State_check();
nanjo 9:8538fc8f6259 45 void check();
nanjo 9:8538fc8f6259 46 char CIRCLE;
nanjo 9:8538fc8f6259 47 char CROSS;
nanjo 9:8538fc8f6259 48 char SQUARE;
nanjo 9:8538fc8f6259 49 char TRIANGLE;
nanjo 9:8538fc8f6259 50 char L1;
nanjo 9:8538fc8f6259 51 char L2;
nanjo 9:8538fc8f6259 52 char L3;
nanjo 9:8538fc8f6259 53 char R1;
nanjo 9:8538fc8f6259 54 char R2;
nanjo 9:8538fc8f6259 55 char R3;
nanjo 9:8538fc8f6259 56 char UPkey;
nanjo 9:8538fc8f6259 57 char DOWNkey;
nanjo 9:8538fc8f6259 58 char RIGHTkey;
nanjo 9:8538fc8f6259 59 char LEFTkey;
nanjo 9:8538fc8f6259 60 signed char RX;
nanjo 9:8538fc8f6259 61 signed char RY;
nanjo 9:8538fc8f6259 62 signed char LX;
nanjo 9:8538fc8f6259 63 signed char LY;
gotto0 6:da71294502ee 64 char rs_x_check();
gotto0 6:da71294502ee 65 char rs_y_check();
gotto0 6:da71294502ee 66 char ls_x_check();
gotto0 6:da71294502ee 67 char ls_y_check();
gotto0 0:afe58893bfe7 68 ~SBDBT();
gotto0 0:afe58893bfe7 69 };
gotto0 0:afe58893bfe7 70
nanjo 9:8538fc8f6259 71
gotto0 0:afe58893bfe7 72 #endif