Reputation: 249
I have an app support widget and WatchOS, and it has a data store (core data). In the past I used app grouping to communicate among main app, widget and Watch app.
But the watch app is very slow after user upgraded to WatchOS 3.
Now I have rewrite the watch part to be native. It runs smoothly with communication via WatchConnectivity library between main app and WatchOS.
But I cannot find a way to communicate between widget and WatchOS. E.g. if some data get changed due to action by user in the widget, how can I update the data in the WatchOS?
I have tried the updateApplicationContext, but it report either "WCSession has not been activated" or watchApp not installed if the request is from widget.
Help needed! Thanks!
Upvotes: 1
Views: 165
Reputation: 450
I'm pretty certain you can't talk directly from your Today widget to your watch app. Apple's architecture means the watch app can only talk to the associated iOS phone app, and in WatchOS2/3 the watch extension code now runs on the watch itself not the phone.
I'm sure you've thought of these already, but what I what I would do is some/all of the following:
Let us know if you find an good solution for this.
Upvotes: 1