Questions tagged [watchconnectivity]

The WatchConnectivity framework provides a two-way channel for an iOS app to talk to its counterpart WatchKit app and vice-versa. Use this tag when asking for help with Apple's WatchConnectivity Framework.

The WatchConnectivity framework provides a two-way channel for an iOS app to talk to its counterpart WatchKit app and vice-versa. This framework provides classes that allow both components (the iOS app and the WatchKit) to share data with each other.

The WCSession class, the heart of this framework, provides communication methods that can allow simple transfers like messages, to full-blown file transfers.

WatchConnectivity Framework Reference

249 questions
6
votes
2 answers

Error: "Message reply took too long" - WCSession Watch OS2

So I am using Watch Connectivity to request an array from the iPhone to the Watch. The idea was to sendMessage from the watch, and the iPhone will reply with the array within the didReceiveMessage method. However the iPhone does not seem to be…
RileyDev
  • 2,950
  • 3
  • 26
  • 61
5
votes
0 answers

How to Communicate to a WatchOS App from a MacOS App?

I know how one may communicate between iOS apps and watchOS apps using Watch Connectivity. I see it works for Mac Catalyst, but not normal MacOS Apps. Is there a similar way I could communicate between a macOS app and a watchOS app (using Swift)? I…
PersonDudeGuy
  • 113
  • 1
  • 4
5
votes
0 answers

WCSession is not paired getting error in iPhone to iWatch simulators to share data between in Swift

I am working on workouts application for iWatch. I am trying to sharing data from watch to phone, But, I am getting WCSession is not paired error. ViewController.Swift import UIKit import WatchConnectivity class ViewController:…
5
votes
1 answer

How can I diagnose and resolve a crash on WCSession sendMessage(_:replyHandler:errorHandler:)?

I'm building a watchOS app that needs to periodically request information from a companion iPhone app to refresh a complication. To achieve this, I have a WKApplicationRefreshBackgroundTask that runs periodically. It uses…
gohnjanotis
  • 6,513
  • 6
  • 37
  • 57
5
votes
0 answers

After restarting Apple Watch WCSession 'isRechable' returning false every time

I want to display data from firebase realtime database in watch app. I have one method to fetch data from firebase in iOS parent App. From watch app I am sending message to iOS parent app, iOS parent app will fetch data from firebase and reply to…
Krupa Kadecha
  • 1,056
  • 8
  • 8
5
votes
2 answers

How can i check from watch app that if user logged-in or not into the phone application

I am trying to add watch extension to my existing application. Login is compulsory for my application. How can i check from watch app if user logged-in or not... and as user gets loged-in, I want to pass that login-data from the application to the…
adm v
  • 81
  • 9
5
votes
0 answers

WCSession fails to activate on paired watch and phone simulators

Overview: I am building a very simple Apple Watch and iPhone app I am running/debugging the apps using the watch and phone simulators in Xcode I am using WatchConnectivity to make them communicate I cannot activate a WCSession on either the watch…
mosene
  • 124
  • 1
  • 6
5
votes
1 answer

WatchConnectivity timeout error between iPhone and Apple Watch

I am trying to send a string from my apple watch to my iPhone using the WatchConnectivity framework. I have started two sessions, one WCSession and a HKSession because I want to transfer heart rate information from the watch to the iPhone as it is…
dcampb
  • 329
  • 2
  • 11
5
votes
0 answers

Apple Watch Core Motion Data On iPhone?

So, WatchOS 2 supports the core motion framework and allows an active WatchKit app to access data from the Apple Watch accelerometer. I would like to access that data, but on the iPhone. Is there any other way to do this other than opening an app on…
Simon
  • 304
  • 2
  • 17
5
votes
4 answers

didReceiveApplicationContext not being called

I have just set up WCConnectivity in my app using tutorials/sample code and I feel I have it implemented correctly. I am not using the simulator to test. For some reason, the didReceiveApplicationContext is not being called in the watch app, even…
emleeh
  • 106
  • 1
  • 5
5
votes
1 answer

Where best to call updateApplicationContext using Watch Connectivity?

Several of the good blog posts detailing Watch Connectivity (http://www.kristinathai.com/watchos-2-tutorial-using-application-context-to-transfer-data-watch-connectivity-2/ and http://natashatherobot.com/watchconnectivity-application-context/) use…
GarySabo
  • 5,806
  • 5
  • 49
  • 124
5
votes
1 answer

Is it safe to share access tokens with Watch Connectivity's updateApplicationContext?

Is the applicationContext encrypted? Or is it simply stored as an unencrypted plist file? Because if it's the latter, I shouldn't be transferring access tokens using that.
rounak
  • 9,217
  • 3
  • 42
  • 59
4
votes
1 answer

WCSession "isComplicationEnabled" always returns false in iOS 15.4

Since I've updated my test device (iPhone 12 mini) to the latest iOS version 15.4, the complications of my companion app on the watch (watchOS 8.5) do not receive any updates sent by the iOS app. To reproduce the issue you need: An iOS app with an…
4
votes
1 answer

Problem with WatchConnectivity transferFile (watch -> iphone)

I want to send a file created on the watch to the iOS companion-app, using WatchConnectivity and a setup WCSession, but it does not get through to the iPhone. When I use send a message containing a Dictionary in stead, the data does get to the…
4
votes
1 answer

Sometimes WatchConnectivity session on paired watch simulator is not reachable

I have an iOS app that communicates with the paired watch using WatchConnectivity. In most cases, it works without problems, on the simulators and on the devices. The problem: During development on the simulators, I get now and then the following…
Reinhard Männer
  • 14,022
  • 5
  • 54
  • 116
1
2
3
16 17