本文介绍如何在OpenHarmony4.1 SDK中添加默认应用,本次使用了触觉智能Purple Pi OH鸿蒙开源主板,搭载了瑞芯微RK3566芯片,类树莓派设计
1、开发流程
ohos_prebuilt_etc("NFC_hap") {
source = "NFC.hap"
module_install_dir = "app/com.ohos.NFC"
part_name = "prebuilt_hap"
subsystem_name = "applications"
}
如下图所示:
group("hap") {
deps = [
···
"//applications/standard/hap:NFC_hap",
···
]
if (defined(product_name) && product_name == "watchos") {
deps -= [
···
"//applications/standard/hap:NFC_hap",
···
]
}
···
}
如下图所示:
vendor/hihope/rk3568/preinstall-config/install_list.json
添加代码"install_list" : [
···
{
"app_dir" : "/system/app/com.ohos.NFC",
"removable" : false
},
···]
支持OpenHarmony/Andriod/Linux多
操作系统,兼容树莓派;