Last active
May 13, 2016 14:45
-
-
Save choipd/3bf8e6aedc7ba030771ad1de36741a4f to your computer and use it in GitHub Desktop.
Write something to BLE printer.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (IBAction)printHelloWorld:(id)sender { | |
NSString * str = @"Hello World\n\r"; | |
NSData* data = [str dataUsingEncoding:NSUTF8StringEncoding]; | |
[self.printerPeripheral writeValue:data forCharacteristic:self.writeCharacteristic type:CBCharacteristicWriteWithoutResponse]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment