错误症状:
-(void)peripheral:(CBPeripheral *)peripheral didUpdateNotificationStateForCharacteristic:(CBCharacteristic *)characteristic error:(NSError *)error{
if (error) {
JWLog(@"%@",[error localizedDescription]);
return;
}
JWLog(@"updateNotification");
}
该代理抛出错误:invalid handle error
解决方法:将蓝牙重新启动,错误消失,连接正常
参考:http://stackoverflow.com/questions/25139916/setting-notifications-on-characteristic-results-in-invalid-handle-error