![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
Arm control program for Yozakura
MEMS/MEMS.h@0:6b3497b2f2ec, 2015-04-24 (annotated)
- Committer:
- masasin
- Date:
- Fri Apr 24 01:55:32 2015 +0000
- Revision:
- 0:6b3497b2f2ec
Initial commit
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
masasin | 0:6b3497b2f2ec | 1 | #ifndef MBED_MEMS_H |
masasin | 0:6b3497b2f2ec | 2 | #define MBED_MEMS_H |
masasin | 0:6b3497b2f2ec | 3 | |
masasin | 0:6b3497b2f2ec | 4 | #include "mbed.h" |
masasin | 0:6b3497b2f2ec | 5 | |
masasin | 0:6b3497b2f2ec | 6 | #define D6T_addr 0x14 |
masasin | 0:6b3497b2f2ec | 7 | #define D6T_cmd 0x4c |
masasin | 0:6b3497b2f2ec | 8 | |
masasin | 0:6b3497b2f2ec | 9 | class MEMS { |
masasin | 0:6b3497b2f2ec | 10 | public: |
masasin | 0:6b3497b2f2ec | 11 | /* @param sda : I2C pin |
masasin | 0:6b3497b2f2ec | 12 | @param scl : I2C pin |
masasin | 0:6b3497b2f2ec | 13 | */ |
masasin | 0:6b3497b2f2ec | 14 | MEMS(PinName sda, PinName scl); |
masasin | 0:6b3497b2f2ec | 15 | |
masasin | 0:6b3497b2f2ec | 16 | /* |
masasin | 0:6b3497b2f2ec | 17 | @param datr : temperature data[16] |
masasin | 0:6b3497b2f2ec | 18 | */ |
masasin | 0:6b3497b2f2ec | 19 | void temp(float* datr); |
masasin | 0:6b3497b2f2ec | 20 | |
masasin | 0:6b3497b2f2ec | 21 | private: |
masasin | 0:6b3497b2f2ec | 22 | I2C _mems; |
masasin | 0:6b3497b2f2ec | 23 | }; |
masasin | 0:6b3497b2f2ec | 24 | |
masasin | 0:6b3497b2f2ec | 25 | #endif |