Reputation: 1249
My RFDuino is sending data every 2 seconds.
I can see what's being sent via the Arduino Serial manager but I'd like to log this out in Xcode.
What method do I need to use to NSLog this?
Upvotes: 0
Views: 104
Reputation: 1792
Set RFDuinoDelegate to your view. DidReceive method should be called automatically with the data been sent from the rfduino
Example here with receiving string data in Swift
func didReceive(data: NSData!) {
var stringData: String = NSString(data: data, encoding: NSUTF8StringEncoding)! as! String
}
Upvotes: 0