Skip to content
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

BDX transfer support for Python tests #34821

Open
wants to merge 55 commits into
base: master
Choose a base branch
from

Conversation

harimau-qirex
Copy link
Contributor

Add support for BDX transfers to the Python tests.

This allows Python tests to wait for BDX transfers, inspect the init message's details, accept or reject the transfer, and send or receive data. This assists with writing tests for the OTA requestor and diagnostic logs clusters that involve BDX transfers. The code takes some inspiration from the existing BDX transfer server code in src/protocols/bdx, and I think it's worth following up at some point to expand the capabilities of that code to reduce the amount of code specific to the Python controller code introduced in this change.

Included is a test that uses the diagnostic logs cluster on the all clusters app to initiate and complete a BDX transfer.

Copy link

semanticdiff-com bot commented Aug 6, 2024

@github-actions github-actions bot added controller matter-1.4-te2-script-change Script changes before end of Matter 1.4 TE2 labels Aug 6, 2024
Copy link

github-actions bot commented Aug 6, 2024

PR #34821: Size comparison from 83dc1c8 to 5a28be5

Full report (84 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
platform target config section 83dc1c8 5a28be5 change % change
bl602 lighting-app bl602 FLASH 1277798 1277798 0 0.0
RAM 95896 95896 0 0.0
bl602+mfd FLASH 1292056 1292056 0 0.0
RAM 96048 96048 0 0.0
bl602+rpc FLASH 1317014 1317014 0 0.0
RAM 104320 104320 0 0.0
bl702 lighting-app bl702 FLASH 1098938 1098938 0 0.0
RAM 15249 15249 0 0.0
bl702+mfd FLASH 1109888 1109888 0 0.0
RAM 15393 15393 0 0.0
bl702+rpc FLASH 1189260 1189260 0 0.0
RAM 24245 24245 0 0.0
bl706-eth FLASH 881972 881972 0 0.0
RAM 27352 27352 0 0.0
bl706-wifi FLASH 1135150 1135150 0 0.0
RAM 14685 14685 0 0.0
bl702l lighting-app bl702l FLASH 1086100 1086100 0 0.0
RAM 21804 21804 0 0.0
bl702l+mfd FLASH 1097362 1097362 0 0.0
RAM 21956 21956 0 0.0
cc13x4_26x4 lighting-app LP_EM_CC1354P10_6 FLASH 802792 802792 0 0.0
RAM 117620 117620 0 0.0
lock-ftd LP_EM_CC1354P10_6 FLASH 818612 818612 0 0.0
RAM 125220 125220 0 0.0
lock-mtd LP_EM_CC1354P10_6 FLASH 810904 810904 0 0.0
RAM 119500 119500 0 0.0
pump-app LP_EM_CC1354P10_6 FLASH 763244 763244 0 0.0
RAM 113640 113640 0 0.0
pump-controller-app LP_EM_CC1354P10_6 FLASH 747752 747752 0 0.0
RAM 113832 113832 0 0.0
cc32xx air-purifier CC3235SF_LAUNCHXL FLASH 612286 612286 0 0.0
RAM 205380 205380 0 0.0
lock CC3235SF_LAUNCHXL FLASH 654790 654790 0 0.0
RAM 205620 205620 0 0.0
cyw30739 light CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 671905 671905 0 0.0
RAM 78348 78348 0 0.0
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 691765 691765 0 0.0
RAM 80980 80980 0 0.0
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 691765 691765 0 0.0
RAM 80980 80980 0 0.0
CYW930739M2EVB-02 unknown 2040 2040 0 0.0
FLASH 648693 648693 0 0.0
RAM 73416 73416 0 0.0
light-switch CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 610409 610409 0 0.0
RAM 71340 71340 0 0.0
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 630037 630037 0 0.0
RAM 73892 73892 0 0.0
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 630037 630037 0 0.0
RAM 73892 73892 0 0.0
lock CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 627753 627753 0 0.0
RAM 74356 74356 0 0.0
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 647469 647469 0 0.0
RAM 76908 76908 0 0.0
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 647469 647469 0 0.0
RAM 76908 76908 0 0.0
thermostat CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 601117 601117 0 0.0
RAM 68372 68372 0 0.0
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 620969 620969 0 0.0
RAM 71004 71004 0 0.0
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 620969 620969 0 0.0
RAM 71004 71004 0 0.0
efr32 lighting-app BRD4187C FLASH 929832 929824 -8 -0.0
RAM 135148 135148 0 0.0
lock-app BRD4338a FLASH 737132 737124 -8 -0.0
RAM 208436 208436 0 0.0
window-app BRD4187C FLASH 1015508 1015508 0 0.0
RAM 127084 127084 0 0.0
esp32 all-clusters-app c3devkit DRAM 94160 94160 0 0.0
FLASH 1532096 1532096 0 0.0
IRAM 82538 82538 0 0.0
m5stack DRAM 115088 115088 0 0.0
FLASH 1542190 1542190 0 0.0
IRAM 117039 117039 0 0.0
linux air-purifier-app debug unknown 4632 4632 0 0.0
FLASH 2752321 2752321 0 0.0
RAM 128368 128368 0 0.0
all-clusters-app debug unknown 5416 5416 0 0.0
FLASH 6032524 6032524 0 0.0
RAM 510192 510192 0 0.0
all-clusters-minimal-app debug unknown 5312 5312 0 0.0
FLASH 5373438 5373438 0 0.0
RAM 240000 240000 0 0.0
bridge-app debug unknown 5296 5296 0 0.0
FLASH 4727646 4727646 0 0.0
RAM 217024 217024 0 0.0
chip-tool debug unknown 5832 5832 0 0.0
FLASH 12490196 12490196 0 0.0
RAM 557978 557978 0 0.0
chip-tool-ipv6only arm64 unknown 20312 20312 0 0.0
FLASH 11169836 11169836 0 0.0
RAM 607984 607984 0 0.0
fabric-admin debug unknown 5672 5672 0 0.0
FLASH 11472973 11472973 0 0.0
RAM 554714 554714 0 0.0
fabric-bridge-app debug unknown 4568 4568 0 0.0
FLASH 4483254 4483254 0 0.0
RAM 202192 202192 0 0.0
lighting-app debug+rpc+ui unknown 5968 5968 0 0.0
FLASH 5661713 5661713 0 0.0
RAM 228112 228112 0 0.0
lock-app debug unknown 5232 5232 0 0.0
FLASH 4782046 4782046 0 0.0
RAM 203840 203840 0 0.0
ota-provider-app debug unknown 4608 4608 0 0.0
FLASH 4422360 4422360 0 0.0
RAM 197824 197824 0 0.0
ota-requestor-app debug unknown 4544 4544 0 0.0
FLASH 4560968 4560968 0 0.0
RAM 202360 202360 0 0.0
shell debug unknown 4176 4176 0 0.0
FLASH 3074125 3074125 0 0.0
RAM 159112 159112 0 0.0
thermostat-no-ble arm64 unknown 9352 9352 0 0.0
FLASH 4360740 4360740 0 0.0
RAM 242296 242296 0 0.0
tv-app debug unknown 5504 5504 0 0.0
FLASH 6004853 6004853 0 0.0
RAM 583648 583648 0 0.0
tv-casting-app debug unknown 5176 5176 0 0.0
FLASH 10694013 10694013 0 0.0
RAM 645128 645128 0 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 FLASH 908188 908188 0 0.0
RAM 142247 142247 0 0.0
nrf7002dk_nrf5340_cpuapp FLASH 880284 880284 0 0.0
RAM 140386 140386 0 0.0
all-clusters-minimal-app nrf52840dk_nrf52840 FLASH 839828 839828 0 0.0
RAM 141062 141062 0 0.0
nxp contact k32w0+release FLASH 577100 577100 0 0.0
RAM 70472 70472 0 0.0
k32w1+release FLASH 592400 592400 0 0.0
RAM 74456 74456 0 0.0
light k32w0+release FLASH 612544 612544 0 0.0
RAM 69944 69944 0 0.0
k32w1+release FLASH 677384 677384 0 0.0
RAM 83232 83232 0 0.0
psoc6 all-clusters cy8ckit_062s2_43012 FLASH 1637508 1637508 0 0.0
RAM 210928 210928 0 0.0
all-clusters-minimal cy8ckit_062s2_43012 FLASH 1542956 1542956 0 0.0
RAM 207664 207664 0 0.0
light cy8ckit_062s2_43012 FLASH 1463524 1463524 0 0.0
RAM 200776 200776 0 0.0
lock cy8ckit_062s2_43012 FLASH 1462172 1462172 0 0.0
RAM 225120 225120 0 0.0
qpg lighting-app qpg6105+debug FLASH 655596 655596 0 0.0
RAM 105148 105148 0 0.0
lock-app qpg6105+debug FLASH 612896 612896 0 0.0
RAM 99632 99632 0 0.0
stm32 light STM32WB5MM-DK FLASH 477920 477920 0 0.0
RAM 144756 144756 0 0.0
telink air-quality-sensor-app tlsr9528a_retention FLASH 619760 619760 0 0.0
RAM 50936 50936 0 0.0
all-clusters-app tlsr9118bdk40d FLASH 679766 679766 0 0.0
RAM 149576 149576 0 0.0
all-clusters-minimal-app tlsr9528a FLASH 772806 772806 0 0.0
RAM 110732 110732 0 0.0
bridge-app tlsr9258a FLASH 678462 678462 0 0.0
RAM 91624 91624 0 0.0
contact-sensor-app tlsr9528a_retention FLASH 621352 621352 0 0.0
RAM 50980 50980 0 0.0
light-switch-app-ota-shell-factory-data tlsr9528a FLASH 707216 707216 0 0.0
RAM 74316 74316 0 0.0
lighting-app-ota-factory-data tlsr9118bdk40d FLASH 620216 620216 0 0.0
RAM 145580 145580 0 0.0
lighting-app-ota-rpc-factory-data-4mb tlsr9518adk80d FLASH 806302 806302 0 0.0
RAM 99504 99504 0 0.0
lock-app-dfu tlsr9528a FLASH 654094 654094 0 0.0
RAM 67012 67012 0 0.0
ota-requestor-app tlsr9258a FLASH 696496 696496 0 0.0
RAM 91308 91308 0 0.0
pump-app-usb tlsr9518adk80d FLASH 630796 630796 0 0.0
RAM 55756 55756 0 0.0
pump-controller-app tlsr9518adk80d FLASH 608308 608308 0 0.0
RAM 53000 53000 0 0.0
shell tlsr9518adk80d FLASH 466810 466810 0 0.0
RAM 68660 68660 0 0.0
smoke_co_alarm-app tlsr9528a_retention FLASH 628120 628120 0 0.0
RAM 52696 52696 0 0.0
temperature-measurement-app-mars-ota tlsr9518adk80d FLASH 652130 652130 0 0.0
RAM 56636 56636 0 0.0
thermostat tlsr9518adk80d FLASH 633110 633110 0 0.0
RAM 53380 53380 0 0.0
window-covering tlsr9118bdk40d FLASH 522270 522270 0 0.0
RAM 98536 98536 0 0.0
tizen all-clusters-app arm unknown 1588 1588 0 0.0
FLASH 1709228 1709228 0 0.0
RAM 51836 51836 0 0.0
chip-tool-ubsan arm unknown 2404 2404 0 0.0
FLASH 16609890 16609890 0 0.0
RAM 7294528 7294528 0 0.0

Also remove an unnecessary conversion to bytearray.
Copy link

github-actions bot commented Nov 8, 2024

PR #34821: Size comparison from 0454504 to 69d4db7

Full report (68 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
platform target config section 0454504 69d4db7 change % change
bl602 lighting-app bl602+mfd+littlefs+rpc FLASH 1349358 1349426 68 0.0
RAM 104080 104080 0 0.0
bl702 lighting-app bl702+eth FLASH 649376 649386 10 0.0
RAM 25321 25321 0 0.0
bl702+wifi FLASH 826956 826966 10 0.0
RAM 14053 14053 0 0.0
bl706+mfd+rpc+littlefs FLASH 1055154 1055164 10 0.0
RAM 23893 23893 0 0.0
bl702l lighting-app bl702l+mfd+littlefs FLASH 976520 976530 10 0.0
RAM 16556 16556 0 0.0
cc13x4_26x4 lighting-app LP_EM_CC1354P10_6 FLASH 837860 837876 16 0.0
RAM 123628 123628 0 0.0
lock-ftd LP_EM_CC1354P10_6 FLASH 823776 823792 16 0.0
RAM 125516 125516 0 0.0
pump-app LP_EM_CC1354P10_6 FLASH 770516 770532 16 0.0
RAM 113984 113984 0 0.0
pump-controller-app LP_EM_CC1354P10_6 FLASH 754720 754736 16 0.0
RAM 114192 114192 0 0.0
cc32xx air-purifier CC3235SF_LAUNCHXL FLASH 625910 625926 16 0.0
RAM 205780 205780 0 0.0
lock CC3235SF_LAUNCHXL FLASH 667222 667238 16 0.0
RAM 205932 205932 0 0.0
cyw30739 light CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 679497 679513 16 0.0
RAM 78684 78684 0 0.0
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 699341 699357 16 0.0
RAM 81324 81324 0 0.0
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 699341 699357 16 0.0
RAM 81324 81324 0 0.0
CYW930739M2EVB-02 unknown 2040 2040 0 0.0
FLASH 656285 656301 16 0.0
RAM 73752 73752 0 0.0
light-switch CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 616345 616361 16 0.0
RAM 71644 71644 0 0.0
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 635973 635989 16 0.0
RAM 74188 74188 0 0.0
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 635973 635989 16 0.0
RAM 74188 74188 0 0.0
lock CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 635801 635817 16 0.0
RAM 74692 74692 0 0.0
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 655509 655525 16 0.0
RAM 77236 77236 0 0.0
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 655509 655525 16 0.0
RAM 77236 77236 0 0.0
thermostat CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 611197 611213 16 0.0
RAM 68772 68772 0 0.0
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 631049 631065 16 0.0
RAM 71412 71412 0 0.0
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 631049 631065 16 0.0
RAM 71412 71412 0 0.0
efr32 lock-app BRD4187C FLASH 927628 927628 0 0.0
RAM 160160 160160 0 0.0
BRD4338a FLASH 743680 743696 16 0.0
RAM 233288 233288 0 0.0
window-app BRD4187C FLASH 1018784 1018808 24 0.0
RAM 128260 128260 0 0.0
esp32 all-clusters-app c3devkit DRAM 95328 95328 0 0.0
FLASH 1540452 1540466 14 0.0
IRAM 82542 82542 0 0.0
m5stack DRAM 116256 116256 0 0.0
FLASH 1549250 1549282 32 0.0
IRAM 117039 117039 0 0.0
linux air-purifier-app debug unknown 4712 4712 0 0.0
FLASH 2698811 2698879 68 0.0
RAM 129648 129648 0 0.0
all-clusters-app debug unknown 5552 5552 0 0.0
FLASH 5992540 5992608 68 0.0
RAM 523968 523968 0 0.0
all-clusters-minimal-app debug unknown 5448 5448 0 0.0
FLASH 5328148 5328216 68 0.0
RAM 242480 242480 0 0.0
bridge-app debug unknown 5432 5432 0 0.0
FLASH 4670886 4670954 68 0.0
RAM 218416 218416 0 0.0
chip-tool debug unknown 5984 5984 0 0.0
FLASH 12872126 12872194 68 0.0
RAM 584466 584466 0 0.0
chip-tool-ipv6only arm64 unknown 21400 21400 0 0.0
FLASH 11002640 11002704 64 0.0
RAM 635368 635368 0 0.0
fabric-admin debug unknown 5808 5808 0 0.0
FLASH 11277209 11277239 30 0.0
RAM 584890 584826 -64 -0.0
fabric-bridge-app debug unknown 4688 4688 0 0.0
FLASH 4495154 4495222 68 0.0
RAM 205400 205400 0 0.0
fabric-sync debug unknown 4880 4880 0 0.0
FLASH 5309445 5309077 -368 -0.0
RAM 466960 466872 -88 -0.0
lighting-app debug+rpc+ui unknown 6096 6096 0 0.0
FLASH 5606817 5606881 64 0.0
RAM 228552 228552 0 0.0
lock-app debug unknown 5368 5368 0 0.0
FLASH 4720360 4720428 68 0.0
RAM 204552 204552 0 0.0
ota-provider-app debug unknown 4744 4744 0 0.0
FLASH 4345792 4345860 68 0.0
RAM 198272 198272 0 0.0
ota-requestor-app debug unknown 4680 4680 0 0.0
FLASH 4484194 4484262 68 0.0
RAM 202840 202840 0 0.0
shell debug unknown 4240 4240 0 0.0
FLASH 3011213 3011293 80 0.0
RAM 160368 160368 0 0.0
thermostat-no-ble arm64 unknown 9440 9440 0 0.0
FLASH 4089872 4089952 80 0.0
RAM 242936 242936 0 0.0
tv-app debug unknown 5648 5648 0 0.0
FLASH 5942501 5942565 64 0.0
RAM 596336 596336 0 0.0
tv-casting-app debug unknown 5232 5232 0 0.0
FLASH 11079325 11079389 64 0.0
RAM 694536 694536 0 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 FLASH 915356 915372 16 0.0
RAM 143281 143281 0 0.0
nrf7002dk_nrf5340_cpuapp FLASH 887588 887588 0 0.0
RAM 141468 141468 0 0.0
all-clusters-minimal-app nrf52840dk_nrf52840 FLASH 847612 847628 16 0.0
RAM 142189 142189 0 0.0
nxp contact k32w0+release FLASH 584144 584144 0 0.0
RAM 71044 71044 0 0.0
mcxw71+release FLASH 598688 598696 8 0.0
RAM 63144 63144 0 0.0
light k32w0+release FLASH 611204 611220 16 0.0
RAM 70436 70436 0 0.0
k32w1+release FLASH 685000 685016 16 0.0
RAM 48776 48776 0 0.0
lock mcxw71+release FLASH 748528 748544 16 0.0
RAM 67300 67300 0 0.0
psoc6 all-clusters cy8ckit_062s2_43012 FLASH 1642964 1642980 16 0.0
RAM 212056 212056 0 0.0
all-clusters-minimal cy8ckit_062s2_43012 FLASH 1550164 1550180 16 0.0
RAM 208856 208856 0 0.0
light cy8ckit_062s2_43012 FLASH 1466604 1466620 16 0.0
RAM 200840 200840 0 0.0
lock cy8ckit_062s2_43012 FLASH 1464780 1464796 16 0.0
RAM 225200 225200 0 0.0
qpg lighting-app qpg6105+debug FLASH 662168 662184 16 0.0
RAM 105380 105380 0 0.0
lock-app qpg6105+debug FLASH 620268 620284 16 0.0
RAM 99832 99832 0 0.0
stm32 light STM32WB5MM-DK FLASH 482968 482984 16 0.0
RAM 144844 144844 0 0.0
telink bridge-app tlsr9258a FLASH 684674 684684 10 0.0
RAM 91528 91528 0 0.0
contact-sensor-app tlsr9528a_retention FLASH 622686 622696 10 0.0
RAM 50464 50464 0 0.0
light-switch-app-ota-compress-lzma-shell-factory-data tlsr9528a FLASH 710612 710622 10 0.0
RAM 73804 73804 0 0.0
lighting-app-ota-factory-data tlsr9118bdk40d FLASH 628980 628990 10 0.0
RAM 145384 145384 0 0.0
lighting-app-ota-rpc-factory-data-4mb tlsr9518adk80d FLASH 814868 814878 10 0.0
RAM 100004 100004 0 0.0
tizen all-clusters-app arm unknown 4948 4948 0 0.0
FLASH 1722540 1722580 40 0.0
RAM 90656 90656 0 0.0
chip-tool-ubsan arm unknown 10832 10832 0 0.0
FLASH 18007422 18007550 128 0.0
RAM 7857564 7857676 112 0.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants