Apple Watch

RSS for tag

Discuss hardware-specific topics related to Apple Watch.

Apple Watch Documentation

Posts under Apple Watch tag

326 results found
Sort by:
Post marked as solved
416 Views

Xcode 12.5 WatchOS simulator updateApplicationContext() is broken

Hi, Xcode 12.5's iPhone simulator silently fails in sending its app context via updateApplicationContext() to the Watch simulator. No exception is thrown, so it appears as if everything is ok - but not really because the WatchOS simulator never gets the app context This works fine on real devices as well as earlier versions of Xcode. Doing a updateApplicationContext() from the WatchOS simulator to the paired iPhone simulator does work. I filed a bug report for this issue, because this behavior has been in Xcode 12.5 since the beta version: FB9095737 (Xcode 12.5 WatchOS Simulator never receives application context from iPhone counterpart) Before anyone says "why not debug on a real device instead?", please be aware that due to the pandemic, while I do test on real devices, I can only debug on a simulator. Thanks
Asked Last updated
.
Post marked as solved
59k Views

[Apple Watch] Unable to Check for Update - Not connected to the internet error

Hi. I am pairing my Apple Watch Series 5 to my iPhone running ios 14. The pairing is successful but unable to proceed with the set up because an update is needed to be downloaded first. I updated the os for watch but I keep on getting “Unable to Check for Update - Checking for a software update failed because you are not connected to the internet”. I am definitely connected to the internet. Watch was reset to factory defaults and I am now pairing it as a new device but it fails due to the issue mentioned above.
Asked Last updated
.
Post not yet marked as solved
22 Views

about apple watch heart rate sensors

hello, i am new to this forum, i am interested in learning about the optical heart sensor technology embedded on apple watch for heart rate constant monitor how can can i find more about the technical details thank you
Asked Last updated
.
Post not yet marked as solved
66 Views

How to make NSE Filter working in watchOS.

I have required NSE Entitlements, and make silent push notifications work well in iOS. When I enable com.apple.developer.usernotifications.filtering in watchOS, the notification service extension can not run. When I disable com.apple.developer.usernotifications.filtering in watchOS, the notification service extension work well. So, how to make NSE Filter working in watchOS. Thank you very much,
Asked
by wizjin.
Last updated
.
Post not yet marked as solved
1.2k Views

WatchConnectivity not working on device

I have implemented a very simple iOS + WatchOS app project, where I test how one can communicate with the other. I will paste the code below, but the idea is really simple. Each app has one single screen with a button and a label. Tapping the button will send a message to the counterpart indicating the timestamp when the message was generated. If I run the app on the simulators, everything works fine: messages are sent and received correctly on both the iPhone and the Watch. (You can find a reference gif on imgur.com/ + o1ZQTLp). The problem occurs when I try to run the same apps on my physical devices. Session is activated successfully but messages aren't sent. If I debug the code, I even see the WCSession.isReachable value set to true. When debugging the WatchKit app, I see errorHandler is called on the func sendMessage(), and the error states: WatchConnectivity session on paired device is not reachable. However, the errorHandler isn't called from the iPhone app. Details of my devices: iOS version: 14.0.1 WatchOS version: 7.0.1 I tested this same code before installing the 7.0.1 WatchOS and it worked without any problems, so I wonder if the update introduced some error on the WatchConnectivity framework. Code on the iPhone app: import UIKit import WatchConnectivity class ViewController: UIViewController { 		@IBOutlet weak var messageLabel: UILabel! 		fileprivate var wcSession: WCSession! 		override func viewDidLoad() { 				super.viewDidLoad() 				wcSession = WCSession.default 				wcSession.delegate = self 				wcSession.activate() 		} 		@IBAction func sendMessageAction(_ sender: Any) { 				let message = [ 						"content": "Message sent from iPhone on \(Date())." 				] 				wcSession.sendMessage(message, replyHandler: nil, errorHandler: { error in 						print("Error when sending message: \(error.localizedDescription)") 				}) 		} } extension ViewController: WCSessionDelegate { 		func session(_ session: WCSession, activationDidCompleteWith activationState: WCSessionActivationState, error: Error?) { 				switch activationState { 				case .activated: 						print("WCSession activated successfully") 				case .inactive: 						print("Unable to activate the WCSession. Error: \(error?.localizedDescription ?? "--")") 				case .notActivated: 						print("Unexpected .notActivated state received after trying to activate the WCSession") 				@unknown default: 						print("Unexpected state received after trying to activate the WCSession") 				} 		} 		func session(_ session: WCSession, didReceiveMessage message: [String : Any]) { 				guard let content = message["content"] as? String else { return } 				DispatchQueue.main.async { 						self.messageLabel.text = content 				} 		} 		func sessionDidBecomeInactive(_ session: WCSession) { 		} 		func sessionDidDeactivate(_ session: WCSession) { 		} } Code on the Watch Kit app: import WatchKit import Foundation import WatchConnectivity class InterfaceController: WKInterfaceController { 		@IBOutlet weak var messageLabel: WKInterfaceLabel! 		fileprivate var wcSession: WCSession! 		override func awake(withContext context: Any?) { 				wcSession = WCSession.default 				wcSession.delegate = self 				wcSession.activate() 		} 		@IBAction func sendMessageAction() { 				let message = [ 						"content": "Message sent from Watch on \(Date())." 				] 				wcSession.sendMessage(message, replyHandler: nil, errorHandler: { error in 						print("Error when sending message: \(error.localizedDescription)") 				}) 		} } extension InterfaceController: WCSessionDelegate { 		func session(_ session: WCSession, activationDidCompleteWith activationState: WCSessionActivationState, error: Error?) { 				switch activationState { 				case .activated: 						print("WCSession activated successfully") 				case .inactive: 						print("Unable to activate the WCSession. Error: \(error?.localizedDescription ?? "--")") 				case .notActivated: 						print("Unexpected .notActivated state received after trying to activate the WCSession") 				@unknown default: 						print("Unexpected state received after trying to activate the WCSession") 				} 		} 		func session(_ session: WCSession, didReceiveMessage message: [String: Any]) { 				guard let content = message["content"] as? String else { return } 				messageLabel.setText(content) 		} }
Asked
by matiasb.
Last updated
.
Post not yet marked as solved
114 Views

How do I read Apple Watch battery level in iPhone app without a companion Apple Watch app?

I’m trying to read the battery level of a connected Apple Watch on an iPhone app. The built-in iOS Batteries widget shows the current Apple Watch battery level, so I know the data is being sent from Apple Watch to iPhone frequently, however I could not find a public API to read the level in my iOS app. My best solution so far was to build an Apple Watch app that periodically sends the battery level of the Apple Watch to the iPhone using WatchConnectivity. Then, I found this app. It can show the battery level of my paired Apple Watch without ever installing an app on the Apple Watch. To try to accomplish this same thing, I have tried a few different approaches. First, I tried Core Bluetooth, but after a lot of exploring, troubleshooting, and asking at a Core Bluetooth lab, I’ve ruled that out since Apple Watch does not expose its battery information that way. I experimented with the External Accessory framework, but that doesn’t seem like the right approach either, since it's for MFi accessories and I couldn't find a way to get Apple Watch info with it. How is it possible to read the Apple Watch battery level in an iPhone app without sending it from a companion Apple Watch app? Or is the app I linked to probably using private APIs?
Asked Last updated
.
Post not yet marked as solved
368 Views

iOS WebSocket error: Default TLS Trust evaluation failed

I'm trying to connect to a web socket server using WatchKit. I already have a Javascript app and a Windows application that can connect to this WebSocket server, but with iOS and WatchOS it fails with the errors below. Any idea how I can figure out what's wrong? I already added the App Transport Security Settings to my plist file. Connection 1: default TLS Trust evaluation failed(-9807) Connection 1: TLS Trust encountered error 3:-9807 Connection 1: encountered error(3:-9807) Connection 1: unable to determine interface type without an established connection
Asked
by coderkid.
Last updated
.
Post not yet marked as solved
31 Views

Customizing the "Return to App" option on the apple watch

Hey guys, I'm trying to create a custom swimming app, and I'd like to add the "When in Session" > "Return to App" option to my app (under settings > general > wake screen > [app name], like the workout app has). Otherwise, the moment I put my watch under water it goes back to the default clock app, when I raise to wake... would anyone happen to know how to do that? Sorry if it's a super obvious answer lol...
Asked
by Bond604.
Last updated
.
Post not yet marked as solved
30 Views

Apple Watch Series 5 will not update

I am having what seems to be a pretty common problem, with no resolution. I tried updating my watch on Saturday, but my phone keeps telling me it is unable to check for update because I’m not connected to the internet. Here is what I have tried: -hard resetting both the phone and the watch multiple times -deleting and reinstalling the watch app -resetting my network connection on the phone -disconnected and reconnecting to wifi -turning on airplane mode while connected to wifi none of this has helped. It’s stuck on an endless loop telling me I’m not connected to the internet. It’s incredibly frustrating to think that such an expensive product may have been rendered as useless due to trying to keep it updated. Any suggestions in addition to what I have already tried?
Asked
by Melissity.
Last updated
.
Post not yet marked as solved
60 Views

Build Dataset: Get Apple Watch data (Gyroscope and Accelerometer) to build activity model

Hello everybody, I am new to Machine Learning but I want to get started with developing CoreML models to try them out in a few apps of my own. What is the best way to build a dataset from Apple Watch data to build an activity model? Do I build an iPhone app that works with the Apple Watch in order to get the data I need, or is there a more direct way to do it through Xcode, maybe? Thank you for for help. Best regards, Tomás
Asked
by tmsm1999.
Last updated
.
Post not yet marked as solved
299 Views

Alternative to MKLocalSearch for WatchOS

I'm trying to search for nearby locations on my WatchKit app, but MKLocalSearch is unsupported on WatchOS. Is there an alternative way to get nearby locations on a WatchKit app?
Asked
by iEvanC.
Last updated
.
Post not yet marked as solved
205 Views

New update for Apple Watch broke the watch

So I recently tried to update my watch. I have an iPhone X iOS 14 and a series 3 watch without cellular. At first it couldn’t download because it didn’t have enough space. I don’t have many apps if any on my watch, so I tried restarting it because I read in another help guide to do that. After I did that, the watch reverted to factory setting and there was no way for me to download the new update because I’m not “connected to the internet” despite having great service and WiFi. The app doesn’t let me use the watch without updating it of course, so now my beloved watch is now an expensive paper weight. Other websites load on my phone so the internet isn’t the problem. I’ve tried resetting everything and resetting the network settings and turning off cellular for the watch app and I can’t access anything on the watch and can’t access settings on the watch app because it only tells me to pair a watch. Please please help.
Asked
by Rubix67.
Last updated
.
Post not yet marked as solved
53 Views

Certified Watch Lug distributor

Dear members, I'm following the guidelines to create watch bands from here: https://developer.apple.com/accessories/watch-bands/ This details the specifications for both the band and the lugs. We will of course take responsibility for the band construction, but the lugs are something that we find we have no sufficient expertise to meet the standard. So my question is: Are there any official and/or certified providers of lugs. Throwing this question into Google brings back entries from about 4 years ago mentioning mostly AVNET. However, all links point to a page announcing that they are no longer manufacturing such lugs. Any pointers on how to make bands with compliant lugs without getting into the business of manufacturing them myself? Thanks!
Asked
by mxw.
Last updated
.
Post not yet marked as solved
91 Views

Iwatch pairing

I am wondering how I can pair my Iwatch again? It unpaired and now is asking for an update, I am connected to the internet so I’m not sure why it says I cannot complete updates due to no internet. Thank you, Karen
Asked Last updated
.
Post not yet marked as solved
127 Views

Unlock Apple Watch app with iOS app subscription?

My team is building an Apple Watch app as a partner to an existing iOS app. In our iOS app we already have a subscription model set up. What we'd like to do is have the Apple Watch app only be available for our subscribers, but we aren't sure is Apple will allow this or if we'll get rejected on app store review. Much searching has not yielded any insight into this topic, so throwing it out to the masses. Has anyone tried to have a subscribers-only Apple Watch app?
Asked
by LOMF.
Last updated
.