|
你好,我用ble模块连接蓝牙读卡器,scan能扫描到设备但是connect的时候报133错误
{"code":133,"peripheralUUID":"3D:B8:33:50:3C:4B","detailErrorCode":"newState:0"}
var ble = api.require('ble');
ble.connect({
peripheralUUID: uid
}, function(ret, err) {
if (ret.status) {
console.log('连接成功!');
api.alert({msg: "连接成功!"});
}else{
console.log('连接失败!');
api.alert({msg: "连接失败!"});
console.log(JSON.stringify(err));
api.alert({msg: JSON.stringify(err)});
}
}); |
|