cordova的插件 支持android 蓝牙设备插件

时间:2019-06-13 09:29:42
【文件属性】:
文件名称:cordova的插件 支持android 蓝牙设备插件
文件大小:14KB
文件格式:RAR
更新时间:2019-06-13 09:29:42
cordova android 蓝牙 本插件支持androd同时连接多个蓝牙 设备,支持同时通信,例子在examples中,设备我在index.js里面写死了,为了便于调试,下载下来的时候稍微改一下, onDeviceList: function(devices) { var deviceList=document.getElementById("deviceList"); deviceList.innerHTML = ""; devices.forEach(function(device) { var name=device.name; var id=device.id; var listItem = document.createElement('li'), html = '' + name + '[' + id+']'; listItem.innerHTML = html; deviceList.appendChild(listItem); if(name.indexOf("HC")>-1){ $ble.devices.W=device; } if(name.indexOf("Gprinter_3915")>-1){ $ble.devices.P1=device; } if(name.indexOf("Gprinter_AAC5")>-1){ $ble.devices.P2=device; } }); }, 改这里
【文件预览】:
cordova-plugin-wbs-ble
----www()
--------ble.js.bak(4KB)
--------ble.js(4KB)
----package.json(555B)
----plugin.xml.bak(1KB)
----src()
--------android()
----examples()
--------css()
--------index.html(2KB)
--------js()
----plugin.xml(1KB)

网友评论

  • 请问有蓝牙消息订阅的功能么
  • 调试半天,不能用
  • 多谢楼主分享
  • 存着,用到的时候需要
  • 请问有蓝牙消息订阅的功能么
  • 多谢楼主分享