CMPS03 Compass library with only PWM support. I2C support will be added shortly, while it will arrive, you may use MBED component library if you wish to use CMPS03 I2C interface

Dependents:   TestBoussole FRC_2018 0hackton_08_06_18 lib_FRC_2019 ... more

Revision:
2:e09ad9c1f751
Parent:
1:2507a3379f17
Child:
3:3e9586433ce5
--- a/CMPS03.cpp	Mon May 21 16:13:10 2018 +0000
+++ b/CMPS03.cpp	Tue May 22 17:15:22 2018 +0000
@@ -2,8 +2,8 @@
 
 CMPS03::CMPS03(PinName pwm, PinName sda, PinName scl, int address) : _boussole(pwm)
 {
-    _boussole.rise(this, &CMPS03::rise);
-    _boussole.fall(this, &CMPS03::fall);
+    _boussole.rise(callback(this, &CMPS03::rise));
+    _boussole.fall(callback(this, &CMPS03::fall));
     _tim.start();
     _i2c = new I2C(sda, scl);
     //Compass designed to work at 100KHz. See datasheet for details.