Skip to content

Commit 38a24ea

Browse files
authored
Merge pull request #20 from SiliconLabs/release-2.9.2
Release 2.9.2
2 parents fa7b5d4 + 7ec1f14 commit 38a24ea

File tree

96 files changed

+47792
-60713
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

96 files changed

+47792
-60713
lines changed
Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
/**
2+
* Copyright (c) 2024 Project CHIP Authors
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
17+
#import <Foundation/Foundation.h>
18+
#import <Matter/MTRBaseClusters.h>
19+
#import <Matter/MTRDefines.h>
20+
21+
NS_ASSUME_NONNULL_BEGIN
22+
23+
/**
24+
* An access grant, which can be represented as an entry in the Matter Access
25+
* Control cluster.
26+
*/
27+
NS_SWIFT_SENDABLE
28+
MTR_NEWLY_AVAILABLE
29+
@interface MTRAccessGrant : NSObject <NSCopying>
30+
31+
- (instancetype)init NS_UNAVAILABLE;
32+
+ (instancetype)new NS_UNAVAILABLE;
33+
34+
/**
35+
* Grant access at the provided level to a specific node on the fabric. The
36+
* provided nodeID must be an operational node identifier.
37+
*/
38+
+ (nullable MTRAccessGrant *)accessGrantForNodeID:(NSNumber *)nodeID privilege:(MTRAccessControlEntryPrivilege)privilege;
39+
40+
/**
41+
* Grant access to any node on the fabric that has a matching CASE Authenticated
42+
* Tag in its operational certificate. The provided caseAuthenticatedTag must
43+
* be a 32-bit unsigned integer with lower 16 bits not 0, per the Matter
44+
* specification.
45+
*/
46+
+ (nullable MTRAccessGrant *)accessGrantForCASEAuthenticatedTag:(NSNumber *)caseAuthenticatedTag privilege:(MTRAccessControlEntryPrivilege)privilege;
47+
48+
/**
49+
* Grant access to any node on the fabric that is communicating with us via
50+
* group messages sent to the given group. The provided groupID must be a valid
51+
* group identifier in the range 1-65535.
52+
*/
53+
+ (nullable MTRAccessGrant *)accessGrantForGroupID:(NSNumber *)groupID privilege:(MTRAccessControlEntryPrivilege)privilege;
54+
55+
/**
56+
* Grant access to any node on the fabric, as long as it's communicating with us
57+
* over a unicast authenticated channel.
58+
*/
59+
+ (MTRAccessGrant *)accessGrantForAllNodesWithPrivilege:(MTRAccessControlEntryPrivilege)privilege;
60+
61+
/**
62+
* The matter access control subject ID that access has been granted for. Nil
63+
* when access has been granted for all subjects (e.g. via initForAllNodesWithPrivilege).
64+
*/
65+
@property (nonatomic, copy, readonly, nullable) NSNumber * subjectID;
66+
67+
/**
68+
* The privilege that has been granted
69+
*/
70+
@property (nonatomic, assign, readonly) MTRAccessControlEntryPrivilege grantedPrivilege;
71+
72+
/**
73+
* The type of authentication mode the access grant is
74+
* for. MTRAccessControlEntryAuthModeCASE for unicast messages and
75+
* MTRAccessControlEntryAuthModeGroup for groupcast ones.
76+
*/
77+
@property (nonatomic, assign, readonly) MTRAccessControlEntryAuthMode authenticationMode;
78+
79+
@end
80+
81+
NS_ASSUME_NONNULL_END

Matter.framework/Headers/MTRAsyncCallbackWorkQueue.h

Lines changed: 4 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -15,66 +15,35 @@
1515
* limitations under the License.
1616
*/
1717

18-
#import <Foundation/Foundation.h>
18+
#import <Matter/MTRDefines.h>
1919

2020
NS_ASSUME_NONNULL_BEGIN
2121

2222
@class MTRAsyncCallbackQueueWorkItem;
2323

2424
typedef void (^MTRAsyncCallbackReadyHandler)(id context, NSUInteger retryCount);
2525

26-
// MTRAsyncCallbackQueue high level description
27-
// The MTRAsyncCallbackQueue was made to call one readyHandler
28-
// block at a time asynchronously, and the readyHandler is
29-
// expected to start/schedule a task. When the task finishes
30-
// asynchronously in the future (at any time, from any queue
31-
// or thread), it is expected to ask the workItem object to
32-
// either endWork or retryWork.
33-
34-
// Sequence of steps when queuing a work item:
35-
// - Create MTRAsyncCallbackQueueWorkItem object
36-
// - Create ready handler block (MTRAsyncCallbackReadyHandler)
37-
// - block is called when it's the WorkItem's turn to do work
38-
// - its body is to perform a task that is expected to end asynchronously in the future
39-
// - at the end of work, call on the work item object:
40-
// - endWork for success or failure
41-
// - retryWork for temporary failures
42-
// - Set the readyHandler block on the WorkItem object
43-
// - Call enqueueWorkItem on a MTRAsyncCallbackQueue
44-
45-
// A serial one-at-a-time queue for performing work items
26+
MTR_DEPRECATED("This class was not intended to be part of the public Matter API", ios(16.1, 17.2), macos(13.0, 14.2), watchos(9.1, 10.2), tvos(16.1, 17.2))
4627
@interface MTRAsyncCallbackWorkQueue : NSObject
4728
- (instancetype)init NS_UNAVAILABLE;
4829
+ (instancetype)new NS_UNAVAILABLE;
4930

50-
// The context object is only held and passed back as a reference and is opaque to the work queue
5131
- (instancetype)initWithContext:(id _Nullable)context queue:(dispatch_queue_t)queue;
52-
53-
// Called by the work queue owner to clean up and cancel work items
5432
- (void)invalidate;
55-
56-
// Work items may be enqueued from any queue or thread
5733
- (void)enqueueWorkItem:(MTRAsyncCallbackQueueWorkItem *)item;
58-
59-
// TODO: Add a "set concurrency width" method to allow for more than 1 work item at a time
6034
@end
6135

62-
// An item in the work queue
36+
MTR_DEPRECATED("This class was not intended to be part of the public Matter API", ios(16.1, 17.2), macos(13.0, 14.2), watchos(9.1, 10.2), tvos(16.1, 17.2))
6337
@interface MTRAsyncCallbackQueueWorkItem : NSObject
6438
- (instancetype)init NS_UNAVAILABLE;
6539
+ (instancetype)new NS_UNAVAILABLE;
6640

67-
// Both readyHandler and cancelHander will be called on the queue given to initWithQueue
6841
- (instancetype)initWithQueue:(dispatch_queue_t)queue;
42+
6943
@property (nonatomic, strong) MTRAsyncCallbackReadyHandler readyHandler;
7044
@property (nonatomic, strong) dispatch_block_t cancelHandler;
7145

72-
// Called by the creater of the work item when async work is done and should
73-
// be removed from the queue. The work queue will run the next work item.
7446
- (void)endWork;
75-
76-
// Called by the creater of the work item when async work should be retried.
77-
// The work queue will call this workItem's readyHandler again.
7847
- (void)retryWork;
7948
@end
8049

Lines changed: 162 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,162 @@
1+
/**
2+
* Copyright (c) 2023 Project CHIP Authors
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
17+
#import <Foundation/Foundation.h>
18+
19+
#import <Matter/MTRCommandPayloadsObjc.h>
20+
#import <Matter/MTRDefines.h>
21+
#import <Matter/MTRStructsObjc.h>
22+
23+
/**
24+
* This file defines manual backwards-compat shims of various sorts to handle
25+
* API changes that happened.
26+
*/
27+
28+
NS_ASSUME_NONNULL_BEGIN
29+
30+
@interface MTRGroupKeyManagementClusterKeySetReadAllIndicesParams ()
31+
/**
32+
* This command used to incorrectly have a groupKeySetIDs field.
33+
*/
34+
@property (nonatomic, copy) NSArray * groupKeySetIDs MTR_DEPRECATED(
35+
"This field has been removed", ios(16.1, 17.0), macos(13.0, 14.0), watchos(9.1, 10.0), tvos(16.1, 17.0));
36+
37+
@end
38+
39+
/**
40+
* FanControl used to have WindSettingMask and WindSupportMask that had
41+
* identical values. Those got replaced with a single WindBitmap. We codegen
42+
* WindSupportMask as an alias of WindBitmap, but we need a manual shim for
43+
* WindSettingMask.
44+
*/
45+
typedef NS_OPTIONS(uint8_t, MTRFanControlWindSettingMask) {
46+
MTRFanControlWindSettingMaskSleepWind MTR_DEPRECATED(
47+
"Please use MTRFanControlWindBitmapSleepWind", ios(16.1, 17.0), macos(13.0, 14.0), watchos(9.1, 10.0), tvos(16.1, 17.0))
48+
= 0x1,
49+
MTRFanControlWindSettingMaskNaturalWind MTR_DEPRECATED(
50+
"Please use MTRFanControlWindBitmapNaturalWind", ios(16.1, 17.0), macos(13.0, 14.0), watchos(9.1, 10.0), tvos(16.1, 17.0))
51+
= 0x2,
52+
} MTR_DEPRECATED("Please use MTRFanControlWindBitmap", ios(16.1, 17.0), macos(13.0, 14.0), watchos(9.1, 10.0), tvos(16.1, 17.0));
53+
54+
/**
55+
* For the OTA clusters, first we changed the names of the clusters, and then we
56+
* changed the names of the enums. That means we now have three names for the
57+
* enums (newest name, name before enum name change, name before cluster name
58+
* change). We can only track one old name for things, so just manually add the
59+
* intermediate names.
60+
*/
61+
typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateProviderOTAApplyUpdateAction) {
62+
MTROTASoftwareUpdateProviderOTAApplyUpdateActionProceed MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderApplyUpdateActionProceed", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
63+
= 0x00,
64+
MTROTASoftwareUpdateProviderOTAApplyUpdateActionAwaitNextAction
65+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderApplyUpdateActionAwaitNextAction", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
66+
= 0x01,
67+
MTROTASoftwareUpdateProviderOTAApplyUpdateActionDiscontinue
68+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderApplyUpdateActionDiscontinue", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
69+
= 0x02,
70+
} MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderApplyUpdateAction", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2));
71+
72+
typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateProviderOTADownloadProtocol) {
73+
MTROTASoftwareUpdateProviderOTADownloadProtocolBDXSynchronous
74+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderDownloadProtocolBDXSynchronous", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
75+
= 0x00,
76+
MTROTASoftwareUpdateProviderOTADownloadProtocolBDXAsynchronous
77+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderDownloadProtocolBDXAsynchronous", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
78+
= 0x01,
79+
MTROTASoftwareUpdateProviderOTADownloadProtocolHTTPS
80+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderDownloadProtocolHTTPS", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
81+
= 0x02,
82+
MTROTASoftwareUpdateProviderOTADownloadProtocolVendorSpecific
83+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderDownloadProtocolVendorSpecific", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
84+
= 0x03,
85+
} MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderDownloadProtocol", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2));
86+
87+
typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateProviderOTAQueryStatus) {
88+
MTROTASoftwareUpdateProviderOTAQueryStatusUpdateAvailable
89+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderStatusUpdateAvailable", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
90+
= 0x00,
91+
MTROTASoftwareUpdateProviderOTAQueryStatusBusy
92+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderStatusBusy", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
93+
= 0x01,
94+
MTROTASoftwareUpdateProviderOTAQueryStatusNotAvailable
95+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderStatusNotAvailable", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
96+
= 0x02,
97+
MTROTASoftwareUpdateProviderOTAQueryStatusDownloadProtocolNotSupported
98+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderStatusDownloadProtocolNotSupported", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
99+
= 0x03,
100+
} MTR_DEPRECATED("Please use MTROTASoftwareUpdateProviderStatus", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2));
101+
102+
typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateRequestorOTAAnnouncementReason) {
103+
MTROTASoftwareUpdateRequestorOTAAnnouncementReasonSimpleAnnouncement
104+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorAnnouncementReasonSimpleAnnouncement", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
105+
= 0x00,
106+
MTROTASoftwareUpdateRequestorOTAAnnouncementReasonUpdateAvailable
107+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorAnnouncementReasonUpdateAvailable", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
108+
= 0x01,
109+
MTROTASoftwareUpdateRequestorOTAAnnouncementReasonUrgentUpdateAvailable
110+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorAnnouncementReasonUrgentUpdateAvailable", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
111+
= 0x02,
112+
} MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorAnnouncementReason", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2));
113+
114+
typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateRequestorOTAChangeReason) {
115+
MTROTASoftwareUpdateRequestorOTAChangeReasonUnknown
116+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorChangeReasonUnknown", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
117+
= 0x00,
118+
MTROTASoftwareUpdateRequestorOTAChangeReasonSuccess
119+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorChangeReasonSuccess", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
120+
= 0x01,
121+
MTROTASoftwareUpdateRequestorOTAChangeReasonFailure
122+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorChangeReasonFailure", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
123+
= 0x02,
124+
MTROTASoftwareUpdateRequestorOTAChangeReasonTimeOut
125+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorChangeReasonTimeOut", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
126+
= 0x03,
127+
MTROTASoftwareUpdateRequestorOTAChangeReasonDelayByProvider
128+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorChangeReasonDelayByProvider", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
129+
= 0x04,
130+
} MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorChangeReason", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2));
131+
132+
typedef NS_ENUM(uint8_t, MTROTASoftwareUpdateRequestorOTAUpdateState) {
133+
MTROTASoftwareUpdateRequestorOTAUpdateStateUnknown
134+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorUpdateStateUnknown", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
135+
= 0x00,
136+
MTROTASoftwareUpdateRequestorOTAUpdateStateIdle
137+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorUpdateStateIdle", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
138+
= 0x01,
139+
MTROTASoftwareUpdateRequestorOTAUpdateStateQuerying
140+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorUpdateStateQuerying", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
141+
= 0x02,
142+
MTROTASoftwareUpdateRequestorOTAUpdateStateDelayedOnQuery
143+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorUpdateStateDelayedOnQuery", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
144+
= 0x03,
145+
MTROTASoftwareUpdateRequestorOTAUpdateStateDownloading
146+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorUpdateStateDownloading", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
147+
= 0x04,
148+
MTROTASoftwareUpdateRequestorOTAUpdateStateApplying
149+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorUpdateStateApplying", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
150+
= 0x05,
151+
MTROTASoftwareUpdateRequestorOTAUpdateStateDelayedOnApply
152+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorUpdateStateDelayedOnApply", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
153+
= 0x06,
154+
MTROTASoftwareUpdateRequestorOTAUpdateStateRollingBack
155+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorUpdateStateRollingBack", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
156+
= 0x07,
157+
MTROTASoftwareUpdateRequestorOTAUpdateStateDelayedOnUserConsent
158+
MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorUpdateStateDelayedOnUserConsent", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2))
159+
= 0x08,
160+
} MTR_DEPRECATED("Please use MTROTASoftwareUpdateRequestorUpdateState", ios(16.4, 17.2), macos(13.3, 14.2), watchos(9.4, 10.2), tvos(16.4, 17.2));
161+
162+
NS_ASSUME_NONNULL_END

0 commit comments

Comments
 (0)