oboboboboobo
Fork of omuni by
Diff: omuni.h
- Revision:
- 2:fe76af2dff4d
- Parent:
- 0:c0f3e14f1ed1
- Child:
- 3:51f47bf405a0
diff -r c0f3e14f1ed1 -r fe76af2dff4d omuni.h --- a/omuni.h Tue Oct 10 12:50:39 2017 +0000 +++ b/omuni.h Fri Oct 13 10:10:32 2017 +0000 @@ -1,6 +1,7 @@ #ifndef omuni_H #define omuni_H #include "T_motor.h" +#include "P_motor.h" #include "mbed.h" #define PI 3.14159265359 @@ -9,13 +10,15 @@ class omuni{ private: I2C *i2c; - T_motor m1,m2,m3; + Ticker tick; + P_motor m1,m2,m3; char RXData[dataNum]; int8_t map(int8_t in, int8_t inMin, int8_t inMax, int8_t outMin, int8_t outMax); public: - omuni(I2C* i2c_,int8_t addr1,int8_t addr2,int8_t addr3); + omuni(I2C* i2c_,int8_t addr1,int8_t addr2,int8_t addr3, double delta = 0.1); void out(char rxdata[dataNum],float L = 0.275); + void compute_task(); }; #endif \ No newline at end of file