Talking to the iPhone with WatchConnectivity
Talking to remote servers in a data center somewhere is an important task for any app, but sometimes on the watch it seems redundant. Why talk to a server on another continent when there’s a perfectly good iPhone just a Bluetooth connection away? That’s where the WatchConnectivity framework comes in. Often, we just want to send small bits of data back and forth between the two devices—preferences, small images, or user documents, for instance. WatchConnectivity serves as a bridge between the two apps—in fact, you’ll use the framework on both iOS and watchOS. There are several ways to transfer data back and forth using WatchConnectivity. As we go through them, you’ll implement TapALap’s iPhone app ...
Get Developing for Apple Watch, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.