1.连接蓝牙
(第一次发表博客)
第一步打开蓝牙并搜索附近打印机设备//
startSearch: function() {
var that = this
wx.openBluetoothAdapter({
success: function(res) {
wx.getBluetoothAdapterState({
success: function(res) {
if (res.available) {
if (res.discovering) {
wx.stopBluetoothDevicesDiscovery({
success: function(res) {
console.lo
1