Skip to content

Commit de2557a

Browse files
Merge branch 'master' into TC-SC-4.3-python-test
2 parents d2e5d8c + d3e8903 commit de2557a

File tree

25 files changed

+191
-363
lines changed

25 files changed

+191
-363
lines changed

docs/QUICK_START.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ combination listed below.
1919

2020
| <div style="width:200px">Border Router</div> | <div style="width:200px">Node</div> | Description |
2121
| -------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
22-
| [**ot-br**](https://openthread.io/guides/border-router/build)<br>Thread Border Router <li>RasPi <li>BeagleBone | **lighting-app** <li>[Nordic nRF5x](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/nrfconnect/README.md) <li> [NXP K32W](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/nxp/k32w/k32w0/README.md) <li> [Qorvo QPG6100](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/qpg) <li> [Silicon Labs EFR32](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/efr32/README.md) | The Lighting example is supported by many of the available Thread platforms. See the chip-tool controller instructions for how to actuate the light on/off cluster. |
22+
| [**ot-br**](https://openthread.io/guides/border-router/build)<br>Thread Border Router <li>RasPi <li>BeagleBone | **lighting-app** <li>[Nordic nRF5x](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/nrfconnect/README.md) <li> [NXP K32W](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/nxp/k32w/k32w0/README.md) <li> [Qorvo QPG6100](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/qpg) <li> [Silicon Labs EFR32](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/silabs/README.md) | The Lighting example is supported by many of the available Thread platforms. See the chip-tool controller instructions for how to actuate the light on/off cluster. |
2323
| [**ot-br**](https://openthread.io/guides/border-router/build)<br>Thread Border Router <li>RasPi <li>BeagleBone | **lock-app** <li>[Nordic nRF5x](https://github.com/project-chip/connectedhomeip/tree/master/examples/lock-app/nrfconnect/README.md) <li> [NXP K32W](https://github.com/project-chip/connectedhomeip/tree/master/examples/lock-app/nxp/k32w/k32w0/README.md) <li> [Qorvo QPG6100](https://github.com/project-chip/connectedhomeip/tree/master/examples/lock-app/qpg) <li> [Silicon Labs EFR32](https://github.com/project-chip/connectedhomeip/tree/master/examples/lock-app/efr32/README.md) <li> [TI CC13x2x7](https://github.com/project-chip/connectedhomeip/tree/master/examples/lock-app/cc13x2x7_26x2x7/README.md) | The Lock example is supported by many of the available Thread and Wi-Fi platforms. |
2424

2525
## Controllers

docs/guides/silabs_efr32_software_update.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ all of the EFR32 example applications.
88
## Running the OTA Download scenario
99

1010
- For Matter with OpenThread: Bring up the OpenThread Border Router as
11-
discussed in examples/lighting-app/efr32/README.md and get its operational
11+
discussed in examples/lighting-app/silabs/README.md and get its operational
1212
dataset.
1313

1414
- On a Linux or Darwin platform build the chip-tool and the ota-provider-app

examples/chef/chef.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -730,7 +730,7 @@ def main() -> int:
730730
shell.run_cmd(" ".join(nrf_build_cmds))
731731

732732
elif options.build_target == "silabs-thread":
733-
shell.run_cmd(f"cd {_CHEF_SCRIPT_PATH}/efr32")
733+
shell.run_cmd(f"cd {_CHEF_SCRIPT_PATH}/silabs")
734734
if options.do_clean:
735735
shell.run_cmd(f"rm -rf out/{options.sample_device_type_name}")
736736
efr32_cmd_args = []

examples/light-switch-app/silabs/README.md

+14-6
Original file line numberDiff line numberDiff line change
@@ -254,22 +254,30 @@ combination with JLinkRTTClient as follows:
254254
<info > [SVR] Copy/paste the below URL in a browser to see the QR Code:
255255
<info > [SVR] https://project-chip.github.io/connectedhomeip/qrcode.html?data=CH%3AI34NM%20-00%200C9SS0
256256

257-
**LED 0** shows the overall state of the device and its connectivity. The
258-
following states are possible:
257+
**LED 0**
259258

260-
- Short Flash On (50 ms on/950 ms off): The device is in the
259+
- ICD Configuration (Default) - LED is only active under two circumstances:
260+
261+
1. Factory reset sequence - LED will blink when initiated upon press and hold of
262+
Button 0 after 3 seconds
263+
2. An Identify command was received
264+
265+
- Non-ICD Configuration - shows the overall state of the device and its connectivity. The
266+
following states are possible:
267+
268+
Short Flash On (50 ms on/950 ms off): The device is in the
261269
unprovisioned (unpaired) state and is waiting for a commissioning
262270
application to connect.
263271

264-
- Rapid Even Flashing (100 ms on/100 ms off): The device is in the
272+
Rapid Even Flashing (100 ms on/100 ms off): The device is in the
265273
unprovisioned state and a commissioning application is connected through
266274
Bluetooth LE.
267275

268-
- Short Flash Off (950ms on/50ms off): The device is fully
276+
Short Flash Off (950ms on/50ms off): The device is fully
269277
provisioned, but does not yet have full Thread network or service
270278
connectivity.
271279

272-
- Solid On: The device is fully provisioned and has full Thread
280+
Solid On: The device is fully provisioned and has full Thread
273281
network and service connectivity.
274282

275283
**Push Button 0**

examples/lit-icd-app/silabs/README.md

+14-6
Original file line numberDiff line numberDiff line change
@@ -241,22 +241,30 @@ combination with JLinkRTTClient as follows:
241241
<info > [SVR] Copy/paste the below URL in a browser to see the QR Code:
242242
<info > [SVR] https://project-chip.github.io/connectedhomeip/qrcode.html?data=CH%3AI34NM%20-00%200C9SS0
243243

244-
**LED 0** shows the overall state of the device and its connectivity. The
245-
following states are possible:
244+
**LED 0**
246245

247-
- Short Flash On (50 ms on/950 ms off): The device is in the
246+
- ICD Configuration (Default) - LED is only active under two circumstances:
247+
248+
1. Factory reset sequence - LED will blink when initiated upon press and hold of
249+
Button 0 after 3 seconds
250+
2. An Identify command was received
251+
252+
- Non-ICD Configuration - shows the overall state of the device and its connectivity. The
253+
following states are possible:
254+
255+
Short Flash On (50 ms on/950 ms off): The device is in the
248256
unprovisioned (unpaired) state and is waiting for a commissioning
249257
application to connect.
250258

251-
- Rapid Even Flashing (100 ms on/100 ms off): The device is in the
259+
Rapid Even Flashing (100 ms on/100 ms off): The device is in the
252260
unprovisioned state and a commissioning application is connected through
253261
Bluetooth LE.
254262

255-
- Short Flash Off (950ms on/50ms off): The device is fully
263+
Short Flash Off (950ms on/50ms off): The device is fully
256264
provisioned, but does not yet have full Thread network or service
257265
connectivity.
258266

259-
- Solid On: The device is fully provisioned and has full Thread
267+
Solid On: The device is fully provisioned and has full Thread
260268
network and service connectivity.
261269

262270
**Push Button 0**

examples/lock-app/silabs/README.md

+14-6
Original file line numberDiff line numberDiff line change
@@ -262,22 +262,30 @@ combination with JLinkRTTClient as follows:
262262
<info > [SVR] Copy/paste the below URL in a browser to see the QR Code:
263263
<info > [SVR] https://project-chip.github.io/connectedhomeip/qrcode.html?data=CH%3AI34NM%20-00%200C9SS0
264264

265-
**LED 0** shows the overall state of the device and its connectivity. The
266-
following states are possible:
265+
**LED 0**
267266

268-
- _Short Flash On (50 ms on/950 ms off)_ ; The device is in the
267+
- ICD Configuration (Default) - LED is only active under two circumstances:
268+
269+
1. Factory reset sequence - LED will blink when initiated upon press and hold of
270+
Button 0 after 3 seconds
271+
2. An Identify command was received
272+
273+
- Non-ICD Configuration - shows the overall state of the device and its connectivity. The
274+
following states are possible:
275+
276+
Short Flash On (50 ms on/950 ms off): The device is in the
269277
unprovisioned (unpaired) state and is waiting for a commissioning
270278
application to connect.
271279

272-
- _Rapid Even Flashing_ ; (100 ms on/100 ms off)_ &mdash; The device is in the
280+
Rapid Even Flashing (100 ms on/100 ms off): The device is in the
273281
unprovisioned state and a commissioning application is connected through
274282
Bluetooth LE.
275283

276-
- _Short Flash Off_ ; (950ms on/50ms off)_ &mdash; The device is fully
284+
Short Flash Off (950ms on/50ms off): The device is fully
277285
provisioned, but does not yet have full Thread network or service
278286
connectivity.
279287

280-
- _Solid On_ ; The device is fully provisioned and has full Thread
288+
Solid On: The device is fully provisioned and has full Thread
281289
network and service connectivity.
282290

283291
**LED 1** Simulates the Lock The following states are possible:

examples/platform/silabs/SiWx917/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ declare_args() {
3232
sl_wfx_config_scan = true
3333

3434
# Argument to force enable WPA3 security on rs91x
35-
rs91x_wpa3_transition = false
35+
rs91x_wpa3_transition = true
3636

3737
# use commissionable data for SiWx917
3838
siwx917_commissionable_data = false

examples/platform/silabs/efr32/BUILD.gn

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ declare_args() {
3232
sl_wfx_config_scan = true
3333

3434
# Argument to force enable WPA3 security on rs91x
35-
rs91x_wpa3_transition = false
35+
rs91x_wpa3_transition = true
3636

3737
#default WiFi SSID
3838
chip_default_wifi_ssid = ""

examples/window-app/nrfconnect/main/WindowCovering.cpp

+2
Original file line numberDiff line numberDiff line change
@@ -343,4 +343,6 @@ void WindowCovering::DoPostAttributeChange(intptr_t aArg)
343343
VerifyOrReturn(data != nullptr);
344344

345345
PostAttributeChange(data->mEndpoint, data->mAttributeId);
346+
347+
chip::Platform::Delete(data);
346348
}

scripts/examples/gn_silabs_example.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ if [ "$#" == "0" ]; then
4848
$USAGE
4949
5050
<AppRootFolder>
51-
Root Location of the app e.g: examples/lighting-app/efr32/
51+
Root Location of the app e.g: examples/lighting-app/silabs/
5252
5353
<outputFolder>
5454
Desired location for the output files

src/app/server/Dnssd.cpp

+1-2
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,6 @@ CHIP_ERROR DnssdServer::AdvertiseOperational()
181181
.SetPort(GetSecuredPort())
182182
.SetInterfaceId(GetInterfaceId())
183183
.SetLocalMRPConfig(GetLocalMRPConfig())
184-
.SetTcpSupported(Optional<bool>(INET_CONFIG_ENABLE_TCP_ENDPOINT))
185184
.EnableIpV4(true);
186185

187186
#if CHIP_CONFIG_ENABLE_ICD_SERVER
@@ -255,7 +254,7 @@ CHIP_ERROR DnssdServer::Advertise(bool commissionableNode, chip::Dnssd::Commissi
255254
advertiseParameters.SetDeviceName(chip::Optional<const char *>::Value(deviceName));
256255
}
257256

258-
advertiseParameters.SetLocalMRPConfig(GetLocalMRPConfig()).SetTcpSupported(Optional<bool>(INET_CONFIG_ENABLE_TCP_ENDPOINT));
257+
advertiseParameters.SetLocalMRPConfig(GetLocalMRPConfig());
259258

260259
#if CHIP_CONFIG_ENABLE_ICD_SERVER
261260
AddICDKeyToAdvertisement(advertiseParameters);

src/darwin/Framework/CHIP/templates/availability.yaml

+7
Original file line numberDiff line numberDiff line change
@@ -8608,6 +8608,10 @@
86088608
# for now just start doing that for new additions to it.
86098609
- TestDifferentVendorMeiRequest
86108610
- TestDifferentVendorMeiResponse
8611+
GeneralDiagnostics:
8612+
# Targeting Spring 2024 Matter release
8613+
- PayloadTestRequest
8614+
- PayloadTestResponse
86118615
structs:
86128616
Thermostat:
86138617
# Targeting Spring 2024 Matter release
@@ -8651,6 +8655,9 @@
86518655
- PresetTypeFeaturesBitmap
86528656
- ScheduleTypeFeaturesBitmap
86538657
- TemperatureSetpointHoldPolicyBitmap
8658+
GeneralDiagnostics:
8659+
# Targeting Spring 2024 Matter release
8660+
- Feature
86548661
bitmap values:
86558662
DoorLock:
86568663
Feature:

src/darwin/Framework/CHIPTests/MTRBackwardsCompatTests.m

+21-65
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@
2828
// system dependencies
2929
#import <XCTest/XCTest.h>
3030

31+
// Fixture: chip-all-clusters-app --KVS "$(mktemp -t chip-test-kvs)" --interface-id -1
32+
3133
static const uint16_t kPairingTimeoutInSeconds = 10;
3234
static const uint16_t kCASESetupTimeoutInSeconds = 30;
3335
static const uint16_t kTimeoutInSeconds = 3;
@@ -71,7 +73,7 @@ - (void)onPairingComplete:(NSError *)error
7173
XCTAssertEqual(error.code, 0);
7274

7375
NSError * commissionError = nil;
74-
[sController commissionDevice:kDeviceId commissioningParams:[[MTRCommissioningParameters alloc] init] error:&commissionError];
76+
XCTAssertTrue([sController commissionDevice:kDeviceId commissioningParams:[[MTRCommissioningParameters alloc] init] error:&commissionError]);
7577
XCTAssertNil(commissionError);
7678

7779
// Keep waiting for onCommissioningComplete
@@ -89,64 +91,27 @@ - (void)onCommissioningComplete:(NSError *)error
8991
@interface MTRBackwardsCompatTests : XCTestCase
9092
@end
9193

92-
static BOOL sStackInitRan = NO;
93-
static BOOL sNeedsStackShutdown = YES;
94-
9594
@implementation MTRBackwardsCompatTests
9695

97-
+ (void)tearDown
96+
+ (void)setUp
9897
{
99-
// Global teardown, runs once
100-
if (sNeedsStackShutdown) {
101-
// We don't need to worry about ResetCommissionee. If we get here,
102-
// we're running only one of our test methods (using
103-
// -only-testing:MatterTests/MTROTAProviderTests/testMethodName), since
104-
// we did not run test999_TearDown.
105-
[self shutdownStack];
106-
}
107-
}
108-
109-
- (void)setUp
110-
{
111-
// Per-test setup, runs before each test.
11298
[super setUp];
113-
[self setContinueAfterFailure:NO];
11499

115-
if (sStackInitRan == NO) {
116-
[self initStack];
117-
}
118-
}
119-
120-
- (void)tearDown
121-
{
122-
// Per-test teardown, runs after each test.
123-
[super tearDown];
124-
}
125-
126-
- (void)initStack
127-
{
128-
sStackInitRan = YES;
129-
130-
XCTestExpectation * expectation = [self expectationWithDescription:@"Pairing Complete"];
100+
XCTestExpectation * expectation = [[XCTestExpectation alloc] initWithDescription:@"Pairing Complete"];
131101

132102
__auto_type * factory = [MTRControllerFactory sharedInstance];
133103
XCTAssertNotNil(factory);
134104

135105
__auto_type * storage = [[MTRTestStorage alloc] init];
136106
__auto_type * factoryParams = [[MTRControllerFactoryParams alloc] initWithStorage:storage];
137107
factoryParams.port = @(kLocalPort);
108+
XCTAssertTrue([factory startup:factoryParams]);
138109

139-
BOOL ok = [factory startup:factoryParams];
140-
XCTAssertTrue(ok);
141-
142-
__auto_type * testKeys = [[MTRTestKeys alloc] init];
143-
XCTAssertNotNil(testKeys);
144-
145-
sTestKeys = testKeys;
110+
XCTAssertNotNil(sTestKeys = [[MTRTestKeys alloc] init]);
146111

147112
// Needs to match what startControllerOnExistingFabric calls elsewhere in
148113
// this file do.
149-
__auto_type * params = [[MTRDeviceControllerStartupParams alloc] initWithSigningKeypair:testKeys fabricId:1 ipk:testKeys.ipk];
114+
__auto_type * params = [[MTRDeviceControllerStartupParams alloc] initWithSigningKeypair:sTestKeys fabricId:1 ipk:sTestKeys.ipk];
150115
params.vendorId = @(kTestVendorId);
151116

152117
MTRDeviceController * controller = [factory startControllerOnNewFabric:params];
@@ -164,12 +129,12 @@ - (void)initStack
164129
XCTAssertNotNil(payload);
165130
XCTAssertNil(error);
166131

167-
[controller setupCommissioningSessionWithPayload:payload newNodeID:@(kDeviceId) error:&error];
132+
XCTAssertTrue([controller setupCommissioningSessionWithPayload:payload newNodeID:@(kDeviceId) error:&error]);
168133
XCTAssertNil(error);
169134

170-
[self waitForExpectationsWithTimeout:kPairingTimeoutInSeconds handler:nil];
135+
XCTAssertEqual([XCTWaiter waitForExpectations:@[ expectation ] timeout:kPairingTimeoutInSeconds], XCTWaiterResultCompleted);
171136

172-
__block XCTestExpectation * connectionExpectation = [self expectationWithDescription:@"CASE established"];
137+
__block XCTestExpectation * connectionExpectation = [[XCTestExpectation alloc] initWithDescription:@"CASE established"];
173138
[controller getBaseDevice:kDeviceId
174139
queue:dispatch_get_main_queue()
175140
completionHandler:^(MTRBaseDevice * _Nullable device, NSError * _Nullable error) {
@@ -178,27 +143,24 @@ - (void)initStack
178143
sConnectedDevice = device;
179144
connectionExpectation = nil;
180145
}];
181-
[self waitForExpectationsWithTimeout:kCASESetupTimeoutInSeconds handler:nil];
146+
XCTAssertEqual([XCTWaiter waitForExpectations:@[ connectionExpectation ] timeout:kCASESetupTimeoutInSeconds], XCTWaiterResultCompleted);
182147
}
183148

184-
+ (void)shutdownStack
149+
+ (void)tearDown
185150
{
186-
sNeedsStackShutdown = NO;
187-
188-
MTRDeviceController * controller = sController;
189-
XCTAssertNotNil(controller);
190-
191-
[controller shutdown];
192-
XCTAssertFalse([controller isRunning]);
151+
ResetCommissionee(GetConnectedDevice(), dispatch_get_main_queue(), nil, kTimeoutInSeconds);
193152

153+
[sController shutdown];
154+
XCTAssertFalse([sController isRunning]);
194155
[[MTRControllerFactory sharedInstance] shutdown];
156+
157+
[super tearDown];
195158
}
196159

197-
- (void)test000_SetUp
160+
- (void)setUp
198161
{
199-
// Nothing to do here; our setUp method handled this already. This test
200-
// just exists to make the setup not look like it's happening inside other
201-
// tests.
162+
[super setUp];
163+
[self setContinueAfterFailure:NO];
202164
}
203165

204166
#define CHECK_RETURN_TYPE(sig, type) \
@@ -1210,10 +1172,4 @@ - (void)test048_MTRModeSelectClusterSemanticTagStruct
12101172
CHECK_PROPERTY(obj, value, setValue, NSNumber *);
12111173
}
12121174

1213-
- (void)test999_TearDown
1214-
{
1215-
ResetCommissionee(GetConnectedDevice(), dispatch_get_main_queue(), self, kTimeoutInSeconds);
1216-
[[self class] shutdownStack];
1217-
}
1218-
12191175
@end

0 commit comments

Comments
 (0)