Modified for compatibility with Rev.E. hardware
Fork of AkmSensor by
Diff: ak9750ctrl.cpp
- Revision:
- 13:d008249f0359
- Parent:
- 11:cef8dc1cf010
- Child:
- 15:1238993fd75f
--- a/ak9750ctrl.cpp Wed Aug 10 23:50:53 2016 +0000 +++ b/ak9750ctrl.cpp Fri Aug 12 00:04:48 2016 +0000 @@ -11,6 +11,7 @@ ak9750 = NULL; event = false; interrupt = NULL; + sensorName = ""; } /** @@ -32,6 +33,11 @@ if(subId == SUB_ID_AK9750){ ak9750 = new AK9750(); + sensorName = "AK9750"; + } + else if(subId == SUB_ID_AK9753){ + ak9750 = new AK9750(); + sensorName = "AK9753"; } else{ return AkmSensor::ERROR; @@ -464,3 +470,6 @@ } return status; } +char* Ak9750Ctrl::getSensorName(){ + return sensorName; +}