diff --git a/services/sensorservice/CorrectedGyroSensor.cpp b/services/sensorservice/CorrectedGyroSensor.cpp index 1857443e8..09f60a96e 100644 --- a/services/sensorservice/CorrectedGyroSensor.cpp +++ b/services/sensorservice/CorrectedGyroSensor.cpp @@ -69,7 +69,7 @@ status_t CorrectedGyroSensor::setDelay(void* ident, int handle, int64_t ns) { Sensor CorrectedGyroSensor::getSensor() const { sensor_t hwSensor; hwSensor.name = "Corrected Gyroscope Sensor"; - hwSensor.vendor = "Google Inc."; + hwSensor.vendor = "AOSP"; hwSensor.version = 1; hwSensor.handle = '_cgy'; hwSensor.type = SENSOR_TYPE_GYROSCOPE; diff --git a/services/sensorservice/GravitySensor.cpp b/services/sensorservice/GravitySensor.cpp index c57715f0d..0bf20db2b 100644 --- a/services/sensorservice/GravitySensor.cpp +++ b/services/sensorservice/GravitySensor.cpp @@ -77,7 +77,7 @@ status_t GravitySensor::setDelay(void* ident, int handle, int64_t ns) { Sensor GravitySensor::getSensor() const { sensor_t hwSensor; hwSensor.name = "Gravity Sensor"; - hwSensor.vendor = "Google Inc."; + hwSensor.vendor = "AOSP"; hwSensor.version = 3; hwSensor.handle = '_grv'; hwSensor.type = SENSOR_TYPE_GRAVITY; diff --git a/services/sensorservice/LinearAccelerationSensor.cpp b/services/sensorservice/LinearAccelerationSensor.cpp index f0054f2b3..25ae4736c 100644 --- a/services/sensorservice/LinearAccelerationSensor.cpp +++ b/services/sensorservice/LinearAccelerationSensor.cpp @@ -62,7 +62,7 @@ Sensor LinearAccelerationSensor::getSensor() const { Sensor gsensor(mGravitySensor.getSensor()); sensor_t hwSensor; hwSensor.name = "Linear Acceleration Sensor"; - hwSensor.vendor = "Google Inc."; + hwSensor.vendor = "AOSP"; hwSensor.version = gsensor.getVersion(); hwSensor.handle = '_lin'; hwSensor.type = SENSOR_TYPE_LINEAR_ACCELERATION; diff --git a/services/sensorservice/OrientationSensor.cpp b/services/sensorservice/OrientationSensor.cpp index 037adaa2e..b1463324b 100644 --- a/services/sensorservice/OrientationSensor.cpp +++ b/services/sensorservice/OrientationSensor.cpp @@ -33,6 +33,9 @@ OrientationSensor::OrientationSensor() : mSensorDevice(SensorDevice::getInstance()), mSensorFusion(SensorFusion::getInstance()) { + // FIXME: instead of using the SensorFusion code, we should use + // the SENSOR_TYPE_ROTATION_VECTOR instead. This way we could use the + // HAL's implementation. } bool OrientationSensor::process(sensors_event_t* outEvent, @@ -73,7 +76,7 @@ status_t OrientationSensor::setDelay(void* ident, int handle, int64_t ns) { Sensor OrientationSensor::getSensor() const { sensor_t hwSensor; hwSensor.name = "Orientation Sensor"; - hwSensor.vendor = "Google Inc."; + hwSensor.vendor = "AOSP"; hwSensor.version = 1; hwSensor.handle = '_ypr'; hwSensor.type = SENSOR_TYPE_ORIENTATION; diff --git a/services/sensorservice/RotationVectorSensor.cpp b/services/sensorservice/RotationVectorSensor.cpp index 5ea95683f..725deb4a9 100644 --- a/services/sensorservice/RotationVectorSensor.cpp +++ b/services/sensorservice/RotationVectorSensor.cpp @@ -63,7 +63,7 @@ status_t RotationVectorSensor::setDelay(void* ident, int handle, int64_t ns) { Sensor RotationVectorSensor::getSensor() const { sensor_t hwSensor; hwSensor.name = "Rotation Vector Sensor"; - hwSensor.vendor = "Google Inc."; + hwSensor.vendor = "AOSP"; hwSensor.version = 3; hwSensor.handle = '_rov'; hwSensor.type = SENSOR_TYPE_ROTATION_VECTOR; @@ -112,7 +112,7 @@ status_t GyroDriftSensor::setDelay(void* ident, int handle, int64_t ns) { Sensor GyroDriftSensor::getSensor() const { sensor_t hwSensor; hwSensor.name = "Gyroscope Bias (debug)"; - hwSensor.vendor = "Google Inc."; + hwSensor.vendor = "AOSP"; hwSensor.version = 1; hwSensor.handle = '_gbs'; hwSensor.type = SENSOR_TYPE_ACCELEROMETER; diff --git a/services/sensorservice/SensorFusion.cpp b/services/sensorservice/SensorFusion.cpp index d23906dea..4837b97ae 100644 --- a/services/sensorservice/SensorFusion.cpp +++ b/services/sensorservice/SensorFusion.cpp @@ -28,6 +28,7 @@ SensorFusion::SensorFusion() mEnabled(false), mGyroTime(0) { sensor_t const* list; + Sensor uncalibratedGyro; ssize_t count = mSensorDevice.getSensorList(&list); if (count > 0) { for (size_t i=0 ; i= 0) { - mUserSensorList.removeItemsAt(orientationIndex); - } - } - // debugging sensor list - for (size_t i=0 ; i& connection, int handle); void cleanupAutoDisabledSensor(const sp& connection,