measuringwheel関数がついかされています。

Committer:
UCHITAKE
Date:
Fri Aug 24 04:38:13 2018 +0000
Revision:
0:243364135087
Child:
1:ec87437c2029
Child:
2:b6f5a4994a84
initial commit

Who changed what in which revision?

UserRevisionLine numberNew contents of line
UCHITAKE 0:243364135087 1 #ifndef R1370_H
UCHITAKE 0:243364135087 2 #define R1370_H
UCHITAKE 0:243364135087 3
UCHITAKE 0:243364135087 4 #include "mbed.h"
UCHITAKE 0:243364135087 5 #include <vector>
UCHITAKE 0:243364135087 6
UCHITAKE 0:243364135087 7 #define R1370_BUFFER_SIZE 15
UCHITAKE 0:243364135087 8 #define R1370_HEADER0 0xAA
UCHITAKE 0:243364135087 9 #define R1370_HEADER1 0x00
UCHITAKE 0:243364135087 10
UCHITAKE 0:243364135087 11 class R1370 : public RawSerial
UCHITAKE 0:243364135087 12 {
UCHITAKE 0:243364135087 13 public :
UCHITAKE 0:243364135087 14 R1370(PinName tx, PinName rx);
UCHITAKE 0:243364135087 15
UCHITAKE 0:243364135087 16 float getAngle();
UCHITAKE 0:243364135087 17 float getRate();
UCHITAKE 0:243364135087 18 int16_t getAcc(char l);
UCHITAKE 0:243364135087 19 int16_t getAcc(int i);
UCHITAKE 0:243364135087 20 int16_t getAccX();
UCHITAKE 0:243364135087 21 int16_t getAccY();
UCHITAKE 0:243364135087 22 int16_t getAccZ();
UCHITAKE 0:243364135087 23
UCHITAKE 0:243364135087 24
UCHITAKE 0:243364135087 25 private :
UCHITAKE 0:243364135087 26 void receiveByte();
UCHITAKE 0:243364135087 27 void assembleLoop();
UCHITAKE 0:243364135087 28 void assemble();
UCHITAKE 0:243364135087 29
UCHITAKE 0:243364135087 30 Thread thread;
UCHITAKE 0:243364135087 31 std::vector<unsigned char> buf;
UCHITAKE 0:243364135087 32
UCHITAKE 0:243364135087 33 uint8_t index;
UCHITAKE 0:243364135087 34 int16_t angle;
UCHITAKE 0:243364135087 35 int16_t rate;
UCHITAKE 0:243364135087 36 int16_t acc[3];
UCHITAKE 0:243364135087 37 uint8_t reserved;
UCHITAKE 0:243364135087 38 };
UCHITAKE 0:243364135087 39
UCHITAKE 0:243364135087 40 #endif