Communicate with, configure, and control home automation accessories using HomeKit.

Posts under HomeKit tag

30 Posts

Post

Replies

Boosts

Views

Activity

HomePod mini temperature sensor in HomeKit with Mac Catalyst
Updated version of this post My HomePod mini is now on version 16.4, so the the temperature and humidity sensors are enabled. The data properly shows up in the Home app on my various devices. In my HomeKit iPad app running on Mac Catalyst, however, the data does not show up. I would expect the HomePod mini to show up in HMHome.accessories with a service of type HMServiceTypeTempatureSensor. I see all of my other HomeKit accessories, just not the HomePod mini. I have tried with the latest Xcode (14.3) and highest available iOS Target and Minimum Deployment (16.4), macOS version 13.3. I have not, as of this writing, upgraded my HomeKit architecture, however. Note that I haven't tried the app on an actual iPad (and the iOS simulator doesn't expose my HomeKit environment.)
6
0
1.4k
1d
readValueWithCompletionHandler: limitations?
Are there some undocumented (or, well, documented, but overlooked by me) prerequisites to the readValueWithCompletionHandler: method? The reason I ask is that occasionally I am getting the Read/Write operation failed error in the callback, even in cases where direct, non-deferred reading of the value worked properly. It seems to happen very consistently with some accessories and characteristics, not randomly; thus, it is not likely a temporary quirk in the communication with the device. Probably I am overlooking something of importance, but it does not make a good sense to me. My code (is it right, or can you see anything wrong in there?) // in an HMCharacteristic category if ([self.properties containsObject:HMCharacteristicPropertyReadable]) { id val=self.value, ident=[NSString stringWithFormat:@" [%@] %@ (%@)", self.uniqueIdentifier, self.localizedDescription, self.service.accessory.name]; NSLog(@"nondeferred '%@'%@", val, ident); if (self.service.accessory.reachable) { [self readValueWithCompletionHandler:^(NSError * _Nullable error) { if (error) NSLog(@"deferred ERROR %@ -> %@", ident, error); else NSLog(@"deferred '%@'%@", self.value, ident); }]; } } for most accessories/characteristics works properly, but for some of them I am consistently getting results like nondeferred '70.5' [64998F70-9C11-502F-B8B4-E99DC5C3171B] Current Relative Humidity (Vlhkoměr TH) deferred '70.5' ERROR [64998F70-9C11-502F-B8B4-E99DC5C3171B] Current Relative Humidity (Vlhkoměr TH) -> Error Domain=HMErrorDomain Code=74 "Read/Write operation failed." UserInfo={NSLocalizedDescription=Read/Write operation failed.} Do I do something wrong in my code, or is that normal with some devices? If the latter, is there perhaps a way to know beforehand that I should not use readValueWithCompletionHandler: (for it is bound to fail anyway), and instead I should simply use self.value non-deferred? For some time it seemed to me it happens with bridged accessories, but not really, this hypothesis proved wrong by further testing. Thanks!
2
0
98
1d
Matter Operating Device issue
My team has developed an app with a biref Matter commissioner feature using the Matter framework on the MatterSupport extension. Our app support iOS and Android. However, we ran into a problem that the control certificate generated by the iOS app could not control the device on the Android side. And the control certificate generated by the Android app could not control the device on the iOS side. The Matter library used by Android is compiled by connectedhomeip. Does anyone have the same problem as us? How to solve this? Thank you
2
0
138
2d
Catalyst: determine the device information when running on Mac
When I've tried to use UIDevice on my Mac running my Catalyst application, testing code UIDevice *d=UIDevice.currentDevice; for (NSString *k in @[@"name", @"systemName", @"systemVersion", @"model", @"localizedModel"]) NSLog(@"%@ -> %@", k, [d valueForKey:k]); to my great surprise I am getting name -> iPad systemName -> iPadOS systemVersion -> 26.3 model -> iPad localizedModel -> iPad What the. How do I determine the real values? Thanks!
10
0
161
3d
hide/show scene in Home View API
Which HomeKit API serves for the Home application scene (HMActionSet)-related functionality “Remove from Home View” and “Add to Home View”? There must be a public API for that, for at the very least one 3rd party application shows/hides scenes appropriately as they are set up in Home; nevertheless, whatever I try, I can't find the API. Thanks!
2
0
48
5d
Matter commissioning issue with Matter support extension
My team has developed an app with a Matter commissioner feature (for own ecosystem) using the Matter framework on the MatterSupport extension. Recently, we've noticed that commissioning Matter devices with the MatterSupport extension has become very unstable. Occasionally, the HomeUIService stops the flow after commissioning to the first fabric successfully, displaying the error: "Failed to perform Matter device setup: Error Domain=HMErrorDomain Code=2." (normally, it should send open commissioning window to the device and then add the device to the 2nd fabric). The issue is never seen before until recently few weeks and there is no code changes in the app. We are suspected that there is some data that fail to download from the icloud or apple account that cause this problem. For evaluation, we tried removing the HomeSupport extension and run the Matter framework directly in developer mode, this issue disappears, and commissioning works without any problems.
19
0
817
6d
Home App Intermittent Hub Not Responding Bug
I'm encountering a strange behavior with one of my home's on Home app while I'm off network. When I launch the app it indicates that the hub is not responding and all of my devices are unavailable. However, on the menu bar at the bottom if I switch to "Automation" and back to "Home" the pop-up goes away and my devices are accessible again (sometimes this take a few attempts). Siri is also able to consistently control my devices without an issue. The same behavior occurs with Home app on other devices (e.g. Mac) and with other members that have access to the household. 3rd party HomeKit app like "Controller" does not have an issue. This issue began with iOS 26 and I haven't had much luck resolving the issue. I already tried rebooting everything, including removing and re-adding an Apple TV (home hub). I have other homes shared with me in Home App with similar network/environment that are still working. The home I'm having issues has the most number of devices though (over 100+).
11
0
555
2w
MatterSupport extension MatterAddDeviceExtensionRequestHandler Thread device failure
I am using the MatterSupport extension to commission devices for my own ecosystem. I use the extension to do the initial connection to the device (BLE, PASE, bring device onto wifi/thread) and then use the method commissionDevice(in home: MatterAddDeviceRequest.Home?, onboardingPayload: String, commissioningID: UUID) in MatterAddDeviceExtensionRequestHandler to send a request to my own hub on the local network where it then connects to the device via wifi/thread and fully commissions the device. This flow is working correctly for wifi enabled devices, however it fails for thread devices. For some context, I am using my own border router (and have already added the router's credentials to the phone using THClient's storeCredentials). Here are some device-specific results: ESP32 (WIFI): successful commission ESP32 (THREAD): failure Matter Certified ONVIS smart plug (THREAD): failure The ESP32's are running espressif matter examples. Example border router is a running OTBR docker container I believe that the entire PASE session is established and the device gets onto the thread network, but the process seems to stall after that. I have verified that selectThreadNetwork(...) and validateDeviceCredential(...) get called but the commissioning process seems to stall before it can get to commissionDevice(...) I am limited to 7k characters, but I'll try to include as many relevant log lines as I can near the error if anyone has any ideas. I've already created a bug report with ID: FB18985348 which includes the full logs from the esp32 and a sysdiagnose from an iPhone 12 Pro (iOS 18.5) using the following log profiles: Home app/HomeKit HomeThread ThreadNetwork When commissioning directly from my hub, the entire commissioning completes successfully 100% of the time. This failure only happens when I use MatterSupport to initiate commissioning for Matter over Thread devices specifically. Very condensed homed log overview for uncertified ESP32 thread example Next: 'SecurePairing' -> 'ReadCommissioningInfo' Step: 'ReadCommissioningInfo' Sending read requests for commissioning information NetworkCommissioning Features: has Thread. endpointid = 0 <MTRDeviceController_Concrete: ..., uuid: F9BB9F53-BF73-4B82-B00B-045E7709530E...> completed for nodeID 0x0000000055d193ec with status: Success ✔ 'ReadCommissioningInfo' Next: 'ReadCommissioningInfo' -> 'ArmFailSafe' Step: 'ArmFailSafe' ✔ 'ArmFailSafe' Next: 'ArmFailSafe' -> 'ConfigRegulatory' Step: 'ConfigRegulatory' ✔ 'ConfigRegulatory' Next: 'ConfigRegulatory' -> 'ConfigureTCAcknowledgments' Step: 'ConfigureTCAcknowledgments' ✔ 'ConfigureTCAcknowledgments' Next: 'ConfigureTCAcknowledgments' -> 'SendPAICertificateRequest' Step: 'SendPAICertificateRequest' ✔ 'SendPAICertificateRequest' Next: 'SendPAICertificateRequest' -> 'SendDACCertificateRequest' Step: 'SendDACCertificateRequest' ✔ 'SendDACCertificateRequest' Next: 'SendDACCertificateRequest' -> 'SendAttestationRequest' Step: 'SendAttestationRequest' ✔ 'SendAttestationRequest' Next: 'SendAttestationRequest' -> 'AttestationVerification' Step: 'AttestationVerification' Error on commissioning step 'AttestationVerification': Internal error Next: 'AttestationVerification' -> 'AttestationRevocationCheck' Step: 'AttestationRevocationCheck' (with error) Device attestation error: Integrity check failed. Continue commissioning (ignore attestation failure: YES) ✔ 'AttestationRevocationCheck' Next: 'AttestationRevocationCheck' -> 'SendOpCertSigningRequest' Step: 'SendOpCertSigningRequest' ✔ 'SendOpCertSigningRequest' Next: 'SendOpCertSigningRequest' -> 'ValidateCSR' Step: 'ValidateCSR' ✔ 'ValidateCSR' Next: 'ValidateCSR' -> 'GenerateNOCChain' Step: 'GenerateNOCChain' ✔ 'GenerateNOCChain' Step: 'SendTrustedRootCert' ✔ 'SendTrustedRootCert' Next: 'SendTrustedRootCert' -> 'SendNOC' Step: 'SendNOC' ✔ 'SendNOC' Next: 'SendNOC' -> 'ThreadNetworkSetup' Step: 'ThreadNetworkSetup' ✔ 'ThreadNetworkSetup' Next: 'ThreadNetworkSetup' -> 'FailsafeBeforeThreadEnable' Step: 'FailsafeBeforeThreadEnable' ✔ 'FailsafeBeforeThreadEnable' Next: 'FailsafeBeforeThreadEnable' -> 'ThreadNetworkEnable' Step: 'ThreadNetworkEnable' ✔ 'ThreadNetworkEnable' Next: 'ThreadNetworkEnable' -> 'kEvictPreviousCaseSessions' Step: 'kEvictPreviousCaseSessions' ✔ 'kEvictPreviousCaseSessions' Next: 'kEvictPreviousCaseSessions' -> 'kFindOperationalForStayActive' Step: 'kFindOperationalForStayActive' Error: Timeout Next: 'kFindOperationalForStayActive' -> 'Cleanup' Step: 'Cleanup' (with timeout error) ✔ 'Cleanup' Commissioning complete for node ID 0x0000000055D193EC with timeout error
2
1
274
Dec ’25
Support for custom Matter endpoints, clusters and attributes
I am working on an app for a home automation device. If I were using HomeKit exclusively I could add custom services or custom characteristics on standard services and these things would all be reported to my app via HomeKit. There is sample code from Apple that demonstrates how to do this. When a Matter device is commissioned using HomeKit you might expect custom clusters and/or custom attributes in a standard cluster would be translated to appropriate HomeKit services and characteristics, but this doesn't appear to be the case. Is there a way to have HomeKit do this? If not it seems I would need to use Matter directly rather than via HomeKit to access custom features. But if I commission the device using Matter in my app then I understand a new fabric is created and the device would not show in the Home app. Maybe the user needs to commission the device twice, once with my custom app and once with the Home app? That seems like a poor user experience to me. Perhaps that is the price paid for using a cross-platform standard? Is there a better way to get the same level of customization using Matter that I am able to get using HomeKit?
16
0
2.7k
Oct ’25
Help me
Someone is using all of these tools to hack my phone I have several device and my daughters tabkets and androids are also compromised . Use my home hub / home kit : cloudy it / Xcode / swift ui and siri search . If anyone could help I’d highly appreciate it I have contacted the FBI and have an apt in October b it if someone or anyone could help me debug my phone in the mean time I’d highly appreciate it . Have used my doctors apps and changed iclouds . Used family sharing with my daughter and screen time and have used share across devices . Starting wi try my outlook account that Jeremy Walker had access to . Please help me it’s effects my mental and physical health and quality time with My daughter . Using ethernet and hardware keyboards / voice over and AI . Please assist as this is extremely exhausting help pls
0
0
192
Sep ’25
Sync Conflict Between Contacts & Maps, Possible Cross-App Link with Home App Issue
Pinned 2 homes address for the same contact Steps Initial check in Apple Maps No saved places or pinned addresses appear. Open Personal Contacts You have two addresses stored in your contact card: Main and Home. Pin & Edit “Main” You pinned the Main address in Maps. Refined the location on the map. Renamed it (but still saved under the type “My Home”). Open “Home” Address in Contacts Refined the location again. Changed the type to “My Home.” Attempted to rename, but no option to change the label. Final Saved Places View Shows two entries both called “Main.” Opening either of them displays the same details for the Home address. Saved Places list only shows the full address text, without the ability to rename them inside Maps. Results Both addresses appear duplicated with the same name (“Main”), even though they point to different underlying addresses. When selecting either entry, Apple Maps incorrectly shows the same Home address details. The Saved Places section does not allow renaming; it defaults to showing the full address string. Issues Identified Sync Conflict Between Contacts & Maps Apple Maps pulls labels/types from Contacts, but the edits don’t update consistently across apps. Duplicate Naming Bug Both “Main” and “Home” collapse into “Main” in Saved Places, making them indistinguishable. One-to-One Mapping Failure Regardless of which saved place you open, Maps shows the same Home entry, meaning the system isn’t correctly binding each saved place to its respective contact address. Renaming Limitation Apple Maps doesn’t allow renaming saved addresses directly — it relies on Contacts. Since Contacts only supports preset labels (Home, Work, School, etc.), custom naming is blocked.
1
0
156
Sep ’25
HomePod Mini Beta Device Issues: Power, Connectivity, USB Recognition
Hi! Short time lurker, and first time poster, but I will try to be as descriptive as possible. I have had my HomePod mini since 2021, and have been loving it. Recently, though, I am facing issues which have paralyzed it. Background: Running two HomePod Minis under a stereo pair on the same network in a room. Devices worked well, with the odd dropping of the sound once a while, not too big of an issue. Started running HomePod OS26 beta in July to see what the new updates have, and maybe if the audio issues would be resolved. Issue: Two weeks ago, the after the (then) latest update, there was a no response issue in the app. No big deal, let's just restart the HomePod pair. After restart, no bueno. I also got a new beta software update notification, so decided if I updated them both, the issue will probably be resolved. No dice. The issue persists. So I decided to pair the HomePods and factory reset them. Both HomePods disappeared from my home app. Regular behavior. Going to reset them with the old unplug for 30 s, replug into power, hold finger on the display had no issues for the first one. For the second HomePod, unplug, hold, and plug in. Problems. No display. Tried it a bunch of times, nothing. Waited a day, in case the capacitors needed to be discharged for it to do a cold boot. Nothing. Looking across the interwebs, I found that we can connect the HomePods to Macs, have them show up on Finder, and update from there. Connecting into the Mac, nothing. Waited for the caps to discharge before engaging again, nothing. Now, I fear I may have problems. So I scheduled a meeting at the Genius Bar. Genius Bar individual said no support as you are running beta software. We are not allowed to touch or diagnose those devices. They also said that there are no external facing endpoints for us to diagnose or check. I would have better luck with online Apple Support or over call with Apple Support. Okay, sounds good. Contacting Apple Support, they said that we will have to wait for the official release of HomePodOS 26 for us to support you, to which I agreed. During this time, I thought about seeing if I could troubleshoot and see if anything was coming out of the HomePod when connected to the Mac. So I wrote a script, querying and logging different aspects of the USB controller on the Mac and seeing what device connects. I removed all other USB devices connected to the Mac, and started the script. First, I connected and disconnected the HomePod a couple of times, and on the last connect, I left it in, and let the script record the readings. Reading the output told me that there was indeed a device that was connecting and disconnecting. Here are some of my findings: Port Readout Summary Apple's UVDM stack lights up on the Port-USB-C@2 (CC path, SOP) AppleUVDM driver tried to read identity VDOs, initially rejected, then carried on and the transport finished powering on successfully. Furthermore, the VDM read attempts itself are rejected, typical when the accessory is gating Apple specific commands The CC transport merged metadata for SOP with a 3-VDO identity set. The CC property change during the run indicates an active PD negotiations. USB link states also toggled on that port with driver status Ready Port-USB-C@2/SOP shows Vendor ID and Product ID (not sure if this is private information, so not sharing) Port-USB-C@1/SOP, the e-marker in the HomePod cable shows the same, with product type "Passive Cable" Only CC is flagged "TransportsActive" Apple's accessory authentication stack is present The USB speeds on the port flicker between Gen 3 and Gen 2, indicating to me some sort of handshake failing in the stack, which is preventing enumeration in the System Report and Finder This likely is indicating to me that the target isn't enumerating as a normal USB device, but rather as a USB-PD Vendor Defined Messaging (UVDM) protocol on the CC line. Furthermore, the signature is in a "hidden" service/update modes, which does not enumerate standard USB functions. So, having all this information available to me, I got on a call with Apple Support today, and they went through some of the troubleshooting steps and told me that they could neither escalate the issue (due to it being on a beta software that THEY DO NOT SUPPORT) nor remediate or troubleshoot the issue (as it is an accessory) and the only thing their support options say is to wipe the device, as it is something that is not supported. Upon my suggestion of this my USB logs being used to review the case, they said my personal USB logs would be detrimental towards my case. Their final recommendation was for me to reach out to Apple Developer support as I am running beta software on this HomePod Mini. So, here I am! I highly believe this is a Software issue, contrary to what Apple Consumer Support call representative indicated. All and any help/guidance and support is appreciated. All and any help in boosting the visibility of this issue on the forums would also be greatly appreciated. I have had these bad boys since my undergrad, and I would hate to lose one of them. For Apple Support, before you lock and close this post down and recommend I go to Apple Consumer Support, they said that they cannot help me, and consumer support steps start and end at resetting the device.
0
0
287
Sep ’25
Homepod Crossfade
I’m running HomePod OS 26 on two HomePod minis and OS 18.6 on main HomePod (original) I’ve enabled Crossfade in the Home app. I’m playing Apple Music directly in the HomePod mini. Crossfade just doesn’t work on any HomePod. I can understand it not working on the HomePod - but why isn’t it working on the minis running OS 26? I’ve tried disabling and enabling Crossfade, rebooting HomePods etc but nothing?!
0
0
307
Aug ’25
HomeKit ADK Remote.OpenSSL fails with No setup info found in key-value store during pairing (HAPPlatformAccessorySetup.c:93)
Hello Apple Developers, I'm currently working on building a custom HomeKit Accessory using the HomeKit ADK v6.3 and running the Remote.OpenSSL sample on a Raspberry Pi 4 (64-bit Ubuntu / Linux Kernel 6.1.21-v8+). I'm trying to pair the accessory via the MFi HomeKit ADK pairing process. I've successfully compiled the ADK using: The application (Remote.OpenSSL) launches correctly, and the accessory server starts as expected, broadcasting via mDNS. However, when I attempt to initiate pairing via iOS (or simulate pairing), the following error occurs: Fault fatal error - HAPPlatformAccessorySetupLoadSetupInfo @ PAL/Linux/HAPPlatformAccessorySetup.c:93 This causes the application to crash.
1
0
139
Jul ’25
Homekit Accessory Audio config rejected
I am integrating a camera with HomeKit. The audio and video streams work in the HomeKit Accessory Tester, but they do not work when using the Home app on an iPhone (Failed to select audio config – Could not find the right match in the supported list. Session is not in progress). I have a single audio configuration: Opus 16kHz mono with a constant bitrate of 24kbps.
1
0
108
Jul ’25
Matter communication roundtrip times
I am working on an app (iOS, iPadOS & macOS (Mac Catalyst)) for a Home Automation device. I am using HomeKit APIs to access commissioned devices and provided APIs to get a MatterNodeID and then a MTRBaseDevice so I can query the device. Since the current APIs for accessing Matter devices this way do not support subscriptions I am using the readAttributes() method of the MTRBaseDevice to get information from the device. There can be significant lag time in these reads and I realize my network speed and congestion can contribute to this. The time lag makes me wonder how readAttributes() obtains the data? Does the method query the Home hub which replies using cached data, or does the hub in turn query the device to insure it is providing the latest data? I am pretty sure all this communication goes through the hub because it works whether I am on the same network as the device or in a location far, far away.
1
0
176
Jul ’25
How do I get HomeKit accessories to show up in the iOS Simulator?
I'm finding developing for HomeKit using the iOS Simulator utterly confounding. All of my home's actual HomeKit accessories show up fine when I run the HomeKit app I'm developing on my actual phone. But none show up when I run my app in the iOS Simulator. Maybe that's how it's supposed to be? I decided to run the HomeKit Accessory Simulator in an attempt to get something to show up in the iOS Simulator, but the accessories I've created there don't show up in the Simulator either. How do I get devices to show up in the iOS Simulator? Thanks.
1
0
397
Jun ’25
iOS 18.4 - HomeKit actions from AppIntent fail when triggered from Widget
Hi all, Since updating to iOS 18.4, I'm experiencing a regression with AppIntents triggered from Widgets. In my app, I use AppIntents inside a WidgetKit extension to control HomeKit devices. This setup was working perfectly up to iOS 18.3. However, starting with iOS 18.4, when the AppIntent is triggered from the widget and the main app is not running, the action fails with this error: Error Domain=HMErrorDomain Code=80 "Missing entitlement for API." UserInfo={ NSLocalizedFailureReason=Handler does not support background access, NSLocalizedDescription=Missing entitlement for API. } Interestingly, the exact same AppIntent works fine if the app is still alive in the background — it seems like the failure only occurs when the intent is handled by the widget process. This looks like a behavior change or new restriction introduced in iOS 18.4. Has anyone experienced the same? Is there a new entitlement needed, or a recommended workaround? Thanks in advance!
3
2
373
Jun ’25