平台:C6490,android13
测试项:
Test | Result | Details |
android.app.cts.SystemFeaturesTest#testCameraFeatures | fail |
java.lang.AssertionError: PackageManager#hasSystemFeature should NOT return true for android.hardware.camera
|
Test | Result | Details |
android.app.cts.SystemFeaturesTest#testLocationFeatures | fail |
java.lang.AssertionError: PackageManager#hasSystemFeature should return true for android.hardware.location.gps
|
Test | Result | Details |
android.app.cts.SystemFeaturesTest#testSensorFeatures | fail |
java.lang.AssertionError: PackageManager#hasSystemFeature(android.hardware.sensor.accelerometer) returns true but SensorManager#getSensorList(1) shows sensors [] expected:<true> but was:<false>
|
第一条case 是camera id 获取异常。确认设备camera 是否可以正常打开。发现板子的camera 无法打开。换了个能打开camera的板子,重新测试这个case,报下面错误
java.lang.AssertionError: PackageManager#hasSystemFeature should return true for android.hardware.camera.any
按照需求添加 这个feature : android.hardware.camera.any 在次测试添加新的features
最后,添加如下features ,这个case PASS.
POS:/ $ pm list features | grep camera feature:android.hardware.camera feature:android.hardware.camera.any feature:android.hardware.camera.autofocus feature:android.hardware.camera.capability.manual_post_processing feature:android.hardware.camera.capability.manual_sensor feature:android.hardware.camera.capability.raw feature:android.hardware.camera.level.full
第二条case 是和GPS相关。pm list features 发现少了features
push android.hardware.location.gps.xml 文件到机器中,testLocationFeatures测试PASS
第三条case 是和gsensor相关。
Android 上层裁剪了Feature,但是GetSensorList 中还存在pedometer类型的sensor,所以报错。
不编译 这两个文件。可以删除源文件,因为Android.bp里面是编译的所有cpp文件 "sensors/*.cpp"
LINUX/android/vendor/qcom/proprietary/sensors-see/sensors-hal-2.0/sensors/step_count.cpp
LINUX/android/vendor/qcom/proprietary/sensors-see/sensors-hal-2.0/sensors/step_detect.cpp
修改sensor_list
LINUX/android/vendor/qcom/proprietary/sensors-see/sensors-hal-2.0/sensors/sensors_list.txt
删除 pedometer
PATCH 如下:
deleted: LINUX/android/vendor/qcom/proprietary/sensors-see/sensors-hal-2.0/sensors/step_count.cppdeleted: LINUX/android/vendor/qcom/proprietary/sensors-see/sensors-hal-2.0/sensors/step_detect.cpp
modified: LINUX/android/vendor/qcom/proprietary/sensors-see/sensors-hal-2.0/sensors_list.txt
diff --git a/LINUX/android/vendor/qcom/proprietary/sensors-see/sensors-hal-2.0/sensors_list.txt b/LINUX/android/vendor/qcom/proprietary/sensors-see/sensors-hal-2.0/sensors_list.txt
index e7ae92451e2..49f4c42cd31 100755
--- a/LINUX/android/vendor/qcom/proprietary/sensors-see/sensors-hal-2.0/sensors_list.txt
+++ b/LINUX/android/vendor/qcom/proprietary/sensors-see/sensors-hal-2.0/sensors_list.txt
@@ -8,7 +8,6 @@ accel
gyro
tilt
device_orient
-pedometer
psmd
gyro_cal
sig_motion