-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] iPhone12Mini 16.2 Bluez disconnected immediately for darwin chip-tool with rasp4 chip-lighting-app #24076
Comments
Xcode log:
|
I found it show:
but if I use iPhone SE iOS16.0, it runs well, and pair success with buletooth. |
@robinmo Please see documentation at https://github.com/project-chip/connectedhomeip/blob/master/docs/guides/darwin.md and in particular you need to enable developer mode on your phone and follow the steps https://github.com/project-chip/connectedhomeip/blob/master/docs/guides/darwin.md#profile-installation for this to work. |
@bzbarsky-apple thanks. This error dismiss, after I installed the Bluetooth Central Matter Client Developer mode profile. However, how can I help the app user install this profile if I distribute a matter app? Is it needed for app distributed through Apple App store? |
If you're distributing a Matter app through the app store, it needs to be using the MatterSupport framework. See https://developer.apple.com/documentation/mattersupport |
Hi, @bzbarsky-apple mattersupport is unavailable until 16.1, so if I try to use matter in lower versions of iOS(such as 15.3), how can I fulfill it? |
@robinmo Matter.framework is not available there either, so if you are targeting those versions presumably you are shipping your own version of the whole Matter stack. On versions before MatterSupport is available, you would use that; on versions where MatterSupport is available you use MatterSupport. |
@bzbarsky-apple Thanks. So, go back to the Bluetooth Central Matter Client Developer mode profile, how can I help the app (download from App Store) user install it. |
@robinmo You can't. But that profile is also not needed on iOS versions where MatterSupport does not exist. |
Hi, @bzbarsky-apple I upload a app version with this repo whole matter stack, while without Bluetooth Central Matter Client Developer mode profile commission will fail, and after installing the ble profile it turns out success. So, the profile is needed for iOS versions where MatterSupport does not exist? Then should I deal with installing the profile through my app? |
Again, no. The profile is only needed in 16.1 or newer, where MatterSupport exists. So for things before 16.1 you can use your own Matter.framework (which you are presumably shipping, since that also does not exist before 16.1) and commission over BLE. Starting with 16.1 you need to use MatterSupport. If you want to support both, that needs to be a runtime decision.
Normal users should not be installing this profile, period. For one thing, the profile only works if you enable Developer Mode on your device, and normal users should not be doing that. |
@robinmo I am pretty sure no one has tested Matter.framework on anything before iOS 13. MatterSupport.framework does not exist before 15.x. |
@balducci-apple Many thanks.
|
@robinmo My understanding is that MatterSupport is a Swift-only API. And just to be clear, you would use MatterSupport.framework to generate a setup code and then Matter.framework to commission using that setup code and interact with the device. |
Generate a setup code? You mean pairing code or a QR code payload?
it runs but stuck in the scene below, never get the callback. Another issue about MatterSupport, when integrated with objective-c the bridge file(eg xx-Swift.h) turn out to show error: Xcode Version 14.2 (14C18)
Many thanks for your help. |
I mean that you use MatterSupport.framework to generate a QR code payload, yes. Past that, I'm afraid I can't help you much with MatterSupport, sorry.... |
@robinmo please file a Feedback Assistant request and attach the iOS logs to the ticket.
|
@bzbarsky-apple Hi,I found CHIP can support iOS from iOS11.0, the sample app darwin/CHIPTool use the CoreNFC framework, just need to change its Then run and commission is OK.🎉🎉🎉 |
Hi, @aajain-com @bzbarsky-apple MatterSupport issue has been resolved by adding a matter extension. However here is another problem: we just want to make our mesh device hub to be a controller and it do all the distribution of Node IDs and certificates(such as RAC ICAC). But with MatterSupport for now, I haven't found a way to configure these just as the CHIP do. |
@robinmo What MatterSupport does is bring the device onto the IP network, open a commissioning window, and hand you a setup code you can use to commission the device into your fabric. After that you use Matter.framework to do the commissioning, and you can do your own certificates/etc via that. |
@bzbarsky-apple So, could you provide OCW command related API in MatterSupport? Is it in MTRBaseDevice If no? What's the duration of announcement(As the matter specification says, 5-15min)? And, if expired, how to trigger OCW and get the setup code? We consider that if first commission into apple ecosystem, then open commission window for another ecosystem, the time cost will be bigger than usual(directly commission into the one we want)? Is it the only way to do this(as for resolve ble profile demanded)? It seems quite strange and different from apple style. |
I'm not sure what you're asking for, exactly.
The API you quote will open a commissioning window, yes, if you already have an MTRBaseDevice for an operational device. But that does not sound like your situation, if you have not commissioned the device yet.
The "duration" bit in the selector there.
It is, yes, for devices that need to be commissioned over BLE. Again: use MatterSupport, which will bring the device onto the IP network, open a commissioning window, and give you an onboarding payload that you can use to commission. Then commission using that onboarding payload. |
@bzbarsky-apple Got it. Many thanks. |
@bzbarsky-apple |
Yes... The controller represents the fabric you are trying to bring the device onto, so you need to configure it for that fabric.
How could that possibly work? Again, the controller is supposed to represent your fabric, and you're the only one who knows what the state of that fabric should be.
MatterSupport is supposed to open a commissioning window for you. You just need to create a controller representing your fabric, and then commission the device using that controller.... |
OMG, I supposed the controller is the one that has already commissioned the device.😅 |
Reproduction steps
Bug prevalence
Whenever I do this
GitHub hash of the SDK that was being used
9c0ca13 - Fix Linux standalone job. (#23897)
Platform
darwin
Platform Version(s)
iOS 16.2
Anything else?
rasp4 full log:
The text was updated successfully, but these errors were encountered: