更新记录

1.0.1(2024-07-22)

支持64位

1.0.0(2024-07-20)

华视电子,身份证阅读器


平台兼容性

uni-app

Vue2 Vue3 Chrome Safari app-vue app-nvue Android iOS 鸿蒙
- - - - 4.4 × -
微信小程序 支付宝小程序 抖音小程序 百度小程序 快手小程序 京东小程序 鸿蒙元服务 QQ小程序 飞书小程序 快应用-华为 快应用-联盟
× × × × × × - × × × ×

uni-app x

Chrome Safari Android iOS 鸿蒙 微信小程序
- - 5.0 × - ×

华视电子,身份证阅读器

集成插件

  1. 拷贝demo示例的AndroidManifest.xml到项目根目录
  2. manifest.json -》 app常用其他设置 -》 支持CPU类型,只选择armeabi-v7a
  3. 集成步骤可参考https://www.jianshu.com/p/c1615a7880a7或官网

业务定制需求可**

接口


import {
    ***
} from "@/uni_modules/wrs-huashi-***nfc"
let *** = new ***()
  • 读取模块状态

let ret = ***.***()
if (ret == 0x90) {
    this.***("模块状态良好")
} else {
    this.***("模块状态错误:" + ret)
}
  • 读取基本信息

let *** = plus.io.convertLocalFileSystemURL("_download/aa.png");
let params = {}
params.*** = *** // // 图片保存路径
let result = ***.PICC_Reader_Foreigner***(params)
let ret = result.ret
if (ret == 0 || ret == 1) {
    // ret: 0 中国身份证 1 外国人永久居住证
    this.***("读取成功:" + JSON.stringify(result))
} else {
    this.***("读取失败:" + JSON.stringify(result))
}
  • 读取指纹信息

let *** = plus.io.convertLocalFileSystemURL("_download/bb.png");
let params = {}
params.*** = *** // 图片保存路径
let result = ***.readBaseMsgToStr(params)
if (ret == 0x90) {
    this.***("读取成功:" + JSON.stringify(result))
} else {
    this.***("读取失败:" + JSON.stringify(result))
}
  • 关闭设备

***.closeDevice()

隐私、权限声明

1. 本插件需要申请的系统权限列表:

读写权限

2. 本插件采集的数据、发送的服务器地址、以及数据用途说明:

插件不采集任何数据

3. 本插件是否包含广告,如包含需详细说明广告表达方式、展示频率:

暂无用户评论。