Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CBCharacteristicWriteWithoutResponse怎么操作 #5

Open
kanshenmekan opened this issue Jan 31, 2018 · 1 comment
Open

CBCharacteristicWriteWithoutResponse怎么操作 #5

kanshenmekan opened this issue Jan 31, 2018 · 1 comment

Comments

@kanshenmekan
Copy link

老哥,[_bleManager writeDataWithPeripheral:self.peripheral serviceUUID:@"0xFFE0" writeUUID:@"0xFFE1" data:D callback:nil];
传nil好像不管用
看到代码这里选择TYPE
CBCharacteristicWriteType writeType = callback ? CBCharacteristicWriteWithResponse : CBCharacteristicWriteWithoutResponse ;

@kanshenmekan
Copy link
Author

好像只要执行writeDataWithPeripheral,就会调用[character writeValueWithData:data callback:^(EasyCharacteristic *characteristic, NSData *data, NSError *error) ,这个callback不可能为nil啊,判断只能是CBCharacteristicWriteWithResponse

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant