repositories {
mavenCentral()
}
defaultConfig {
ndk {
abiFilters "armeabi-v7a","arm64-v8a"
}
//目前支持armeabi-v7a和arm64-v8a,请不要在工程中添加x86,不然无法运行
}
dependencies {
// FunSDK 当前最新稳定版本:
implementation 'io.github.xmcamera:libxmfunsdk:2.1'
}
<meta-data
android:name="APP_UUID"
android:value="需要替换的内容" />
<meta-data
android:name="APP_KEY"
android:value="需要替换的内容" />
<meta-data
android:name="APP_SECRET"
android:value="需要替换的内容" />
<meta-data
android:name="APP_MOVECARD"
android:value="需要替换的内容" />
/* 如果是P2P定制服务器的话请参考以下方法
* int customPwdType 加密类型 默认传0
* String customPwd 加密字段 默认传 ""
* String customServerAddr 定制服务器域名或IP
* int customPort 定制服务器端口
* XMFunSDKManager.getInstance(0,"",customServerAddr,customPort).initXMCloudPlatform(this);
*/
XMFunSDKManager.getInstance().initXMCloudPlatform(this);
如果是低功耗设备(门铃、门锁等)还需要调用以下方法:
FunSDK.SetFunIntAttr(EFUN_ATTR.SUP_RPS_VIDEO_DEFAULT, SDKCONST.Switch.Open);
初始化打印:
XMFunSDKManager.getInstance().initLog();