一、添加手动测试指纹模块添加
1. 在测试中显示指纹选项
vendor/mediatek/proprietary/custom/top6739_36_n1/factory/factory.chn.ini
MenuItem=指纹(M);
2
3. 添加手动测试指纹测试代码
vendor/mediatek/proprietary/factory/Android.mk
TEST_SRC_FILES := \
src/test/ftm_finger.c \
vendor/mediatek/proprietary/factory/src/test/ftm_finger.c //测试模块
ftm_init_fn ftm_init_debug_funcs[] = {
#ifdef FEATURE_FTM_FINGERPRINT //TPW_FINGER_PRINT
finger_init,
#endif
}
vendor/mediatek/proprietary/factory/src/factory.cpp
static int auto_test_item_ids[64] = {
ITEM_FINGER,
};
vendor/mediatek/proprietary/factory/inc/common.h
enum {
ITEM_FINGER,
};
vendor/mediatek/proprietary/factory/src/item.cpp
item_t ftm_auto_test_items[] = {
#ifdef FEATURE_FTM_FINGERPRINT
item(ITEM_FINGER, uistr_fingerprint_test),
#endif
}
4.customize /res/FINGERPRINT/microarray_121n/system/oem/oem.prop
ro.device.support.fingerprint=true
5.修改指纹/dev/madev0设备节点的权限
device/fingerprint/microarray/sepolicy/device.te
allow factory finger_device:chr_file { open read getattr write ioctl };
调试方法:
adb shell enforce 0 增加节点权限
1. 在测试中显示指纹选项
vendor/mediatek/proprietary/custom/top6739_36_n1/factory/factory.chn.ini
MenuItem=指纹(M);
2
vendor/mediatek/proprietary/custom/k39tv1_bsp/factory/inc/cust.h
#define FEATURE_FTM_FINGERPRINT3. 添加手动测试指纹测试代码
vendor/mediatek/proprietary/factory/Android.mk
TEST_SRC_FILES := \
src/test/ftm_finger.c \
vendor/mediatek/proprietary/factory/src/test/ftm_finger.c //测试模块
vendor/mediatek/proprietary/factory/src/test/ftm_mods.cpp
extern int finger_init(void);ftm_init_fn ftm_init_debug_funcs[] = {
#ifdef FEATURE_FTM_FINGERPRINT //TPW_FINGER_PRINT
finger_init,
#endif
}
vendor/mediatek/proprietary/factory/src/factory.cpp
static int auto_test_item_ids[64] = {
ITEM_FINGER,
};
vendor/mediatek/proprietary/factory/inc/common.h
enum {
ITEM_FINGER,
};
vendor/mediatek/proprietary/factory/src/item.cpp
item_t ftm_auto_test_items[] = {
#ifdef FEATURE_FTM_FINGERPRINT
item(ITEM_FINGER, uistr_fingerprint_test),
#endif
}
4.customize /res/FINGERPRINT/microarray_121n/system/oem/oem.prop
ro.device.support.fingerprint=true
5.修改指纹/dev/madev0设备节点的权限
device/fingerprint/microarray/sepolicy/device.te
allow factory finger_device:chr_file { open read getattr write ioctl };
调试方法:
adb shell enforce 0 增加节点权限