![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
Diff: invoer/kompas.h
- Revision:
- 0:bec310bde899
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/invoer/kompas.h Tue Sep 27 19:46:30 2011 +0000 @@ -0,0 +1,26 @@ +#ifndef KOMPAS_H +#define KOMPAS_H + +#include "mbed.h" +#include <math.h> + +#define ADDR 0x32 + +class Kompas{ + + I2C compass; // sda, scl + int cal; + int koers,prev; + Ticker refresh; + int opslag[10]; + public: + Kompas(); + int get(void); + void simulate(int); + void update(void); + void startcal(void); + void stopcal(void); +}; + + +#endif