Skip to content

Commit

Permalink
Merge branch 'master' of github.com:duyen-tran/connectedhomeip into d…
Browse files Browse the repository at this point in the history
…uyen-tran/add-opstate-python-scripts
  • Loading branch information
duyen-tran committed Jul 31, 2023
2 parents 9fd8526 + d92ff3f commit 1e350db
Show file tree
Hide file tree
Showing 31 changed files with 772 additions and 199 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/darwin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,12 @@ jobs:
- name: Build example OTA Provider
run: |
scripts/examples/gn_build_example.sh examples/ota-provider-app/linux out/debug chip_config_network_layer_ble=false
- name: Build OTA image files with software version number 5
- name: Build OTA image files with software version number 5 and 10
run: |
scripts/examples/gn_build_example.sh examples/ota-requestor-app/linux out/debug chip_config_network_layer_ble=false non_spec_compliant_ota_action_delay_floor=0 chip_device_config_device_software_version=5 chip_device_config_device_software_version_string='"5.0"'
cp out/debug/chip-ota-requestor-app /tmp/ota-test005-raw-image
cp out/debug/chip-ota-requestor-app /tmp/ota-raw-image-v5
scripts/examples/gn_build_example.sh examples/ota-requestor-app/linux out/debug chip_config_network_layer_ble=false non_spec_compliant_ota_action_delay_floor=0 chip_device_config_device_software_version=10 chip_device_config_device_software_version_string='"10.0"'
cp out/debug/chip-ota-requestor-app /tmp/ota-raw-image-v10
- name: Build example OTA Requestor
run: |
scripts/examples/gn_build_example.sh examples/ota-requestor-app/linux out/debug chip_config_network_layer_ble=false non_spec_compliant_ota_action_delay_floor=0
Expand All @@ -120,6 +122,7 @@ jobs:
# And a different port from the test harness too; the test harness uses port 5541.
../../../out/debug/chip-ota-requestor-app --interface-id -1 --secured-device-port 5542 --discriminator 1111 --KVS /tmp/chip-ota-requestor-kvs1 --otaDownloadPath /tmp/chip-ota-requestor-downloaded-image1 --autoApplyImage > >(tee /tmp/darwin/framework-tests/ota-requestor-app-1.log) 2> >(tee /tmp/darwin/framework-tests/ota-requestor-app-err-1.log >&2) &
../../../out/debug/chip-ota-requestor-app --interface-id -1 --secured-device-port 5543 --discriminator 1112 --KVS /tmp/chip-ota-requestor-kvs2 --otaDownloadPath /tmp/chip-ota-requestor-downloaded-image2 --autoApplyImage > >(tee /tmp/darwin/framework-tests/ota-requestor-app-2.log) 2> >(tee /tmp/darwin/framework-tests/ota-requestor-app-err-2.log >&2) &
../../../out/debug/chip-ota-requestor-app --interface-id -1 --secured-device-port 5544 --discriminator 1113 --KVS /tmp/chip-ota-requestor-kvs3 --otaDownloadPath /tmp/chip-ota-requestor-downloaded-image3 --autoApplyImage > >(tee /tmp/darwin/framework-tests/ota-requestor-app-3.log) 2> >(tee /tmp/darwin/framework-tests/ota-requestor-app-err-3.log >&2) &
# Disable BLE because the app does not have the permission to use
# it and that may crash the CI.
#
Expand Down
2 changes: 1 addition & 1 deletion examples/all-clusters-app/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
otadata, data, ota, , 0x2000,
phy_init, data, phy, , 0x1000,
ota_0, app, ota_0, , 1900K,
Expand Down
2 changes: 1 addition & 1 deletion examples/all-clusters-minimal-app/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
otadata, data, ota, , 0x2000,
phy_init, data, phy, , 0x1000,
ota_0, app, ota_0, , 1500K,
Expand Down
4 changes: 2 additions & 2 deletions examples/bridge-app/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
phy_init, data, phy, , 0x1000,
# Factory partition size about 1.9MB
factory, app, factory, , 1945K,
factory, app, factory, , 1920K,
2 changes: 1 addition & 1 deletion examples/chef/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
phy_init, data, phy, , 0x1000,
# Factory partition size about 1.9MB
factory, app, factory, , 1945K,
2 changes: 1 addition & 1 deletion examples/light-switch-app/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
otadata, data, ota, , 0x2000,
phy_init, data, phy, , 0x1000,
ota_0, app, ota_0, , 1500K,
Expand Down
2 changes: 1 addition & 1 deletion examples/lighting-app/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: Firmware partition offset needs to be 64K aligned, initial 36K (9 sectors) are reserved for bootloader and partition table
esp_secure_cert, 0x3F, , 0xD000, 0x2000, encrypted
nvs, data, nvs, 0x10000, 0x6000,
nvs, data, nvs, 0x10000, 0xC000,
nvs_keys, data, nvs_keys,, 0x1000,
otadata, data, ota, , 0x2000
phy_init, data, phy, , 0x1000,
Expand Down
2 changes: 1 addition & 1 deletion examples/lighting-app/esp32/partitions_encrypted.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
otadata, data, ota, , 0x2000, encrypted
phy_init, data, phy, , 0x1000, encrypted
ota_0, app, ota_0, , 1500K, encrypted
Expand Down
2 changes: 1 addition & 1 deletion examples/lighting-app/esp32/partitions_h2.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
otadata, data, ota, , 0x2000,
phy_init, data, phy, , 0x1000,
ota_0, app, ota_0, , 1500K,
Expand Down
4 changes: 2 additions & 2 deletions examples/lock-app/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
phy_init, data, phy, , 0x1000,
# Factory partition size about 1.9MB
factory, app, factory, , 1945K,
factory, app, factory, , 1920K,
2 changes: 1 addition & 1 deletion examples/ota-provider-app/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
phy_init, data, phy, , 0x1000,
# Factory partition size about 1.6MB
factory, app, factory, , 1600K,
Expand Down
2 changes: 1 addition & 1 deletion examples/ota-requestor-app/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
otadata, data, ota, , 0x2000,
phy_init, data, phy, , 0x1000,
# OTA partitions of size 1.5M each
Expand Down
4 changes: 2 additions & 2 deletions examples/persistent-storage/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
phy_init, data, phy, , 0x1000,
# Factory partition size about 1.9MB
factory, app, factory, , 1945K,
factory, app, factory, , 1920K,
4 changes: 2 additions & 2 deletions examples/pigweed-app/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
phy_init, data, phy, , 0x1000,
# Factory partition size about 1.9MB
factory, app, factory, , 1945K,
factory, app, factory, , 1920K,
4 changes: 2 additions & 2 deletions examples/shell/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
phy_init, data, phy, , 0x1000,
# Factory partition size about 1.9MB
factory, app, factory, , 1945K,
factory, app, factory, , 1920K,
4 changes: 2 additions & 2 deletions examples/temperature-measurement-app/esp32/partitions.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
# Note: if you have increased the bootloader size, make sure to update the offsets to avoid overlap
nvs, data, nvs, , 0x6000,
nvs, data, nvs, , 0xC000,
phy_init, data, phy, , 0x1000,
# Factory partition size about 1.9MB
factory, app, factory, , 1945K,
factory, app, factory, , 1920K,
4 changes: 2 additions & 2 deletions src/darwin/Framework/CHIP/MTRDeviceController.mm
Original file line number Diff line number Diff line change
Expand Up @@ -268,8 +268,8 @@ - (BOOL)startup:(MTRDeviceControllerStartupParamsInternal *)startupParams
}
signingKeypair = &_signingKeypairBridge;
}
errorCode = _operationalCredentialsDelegate->Init(_factory.storageDelegateBridge, signingKeypair, startupParams.ipk,
startupParams.rootCertificate, startupParams.intermediateCertificate);
errorCode = _operationalCredentialsDelegate->Init(
signingKeypair, startupParams.ipk, startupParams.rootCertificate, startupParams.intermediateCertificate);
if ([self checkForStartError:errorCode logMsg:kErrorOperationalCredentialsInit]) {
return;
}
Expand Down
Loading

0 comments on commit 1e350db

Please sign in to comment.