### Install esp-matter-mfg-tool using pip Source: https://github.com/espressif/esp-matter-tools/blob/main/mfg_tool/README.md Install the utility using pip. Ensure you have Python 3 installed. ```bash python3 -m pip install esp-matter-mfg-tool ``` -------------------------------- ### Install Development Dependencies Source: https://github.com/espressif/esp-matter-tools/blob/main/mfg_tool/DEVELOPMENT_GUIDE.md Install the necessary Python packages for development from the requirements.txt file. ```bash python3 -m pip install -r requirements.txt ``` -------------------------------- ### Install Test Dependencies Source: https://github.com/espressif/esp-matter-tools/blob/main/mfg_tool/DEVELOPMENT_GUIDE.md Install the Python packages required for running the unit tests. ```bash python3 -m pip install -r requirements-test.txt ``` -------------------------------- ### Install DMV Tool via PyPI Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/README.md Install the ESP Matter Data Model Validation tool using pip. This is the recommended installation method. ```bash pip install esp-matter-dm-validator ``` -------------------------------- ### Install DMV Tool from Source Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/README.md Clone the repository and install the tool from source. This method is useful for development or if you need the latest changes. ```bash git clone https://github.com/espressif/esp-matter-tools.git cd esp-matter-tools/dmv_tool pip install -e . ``` -------------------------------- ### Install ESP-MATTER MFG Tool in Development Mode Source: https://github.com/espressif/esp-matter-tools/blob/main/mfg_tool/DEVELOPMENT_GUIDE.md Install the tool in editable mode to immediately use changes made in the repository. This is useful when actively developing the tool. ```bash cd tools/mfg_tool python3 -m pip install -e . ``` -------------------------------- ### Attribute Report Example 2 Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_scenes_management_command_missing.txt Example of an AttributeReportIB with a different attribute path (0x0000_000B) and data. ```log [1758019979.223] [98947:37460789:chip] [DMG] AttributeReportIB = { AttributeDataIB = { DataVersion = 0xc9af32ee, AttributePathIB = { Endpoint = 0x0, Cluster = 0x28, Attribute = 0x0000_000B, } Data = "20200101" (8 chars), }, }, ``` -------------------------------- ### Run Web UI Locally Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/README.md Start a local HTTP server to access the Matter Datamodel Validator web application. Navigate to http://localhost:8000 in your browser after starting the server. ```bash cd dmv_tool/ui python3 -m http.server 8000 ``` -------------------------------- ### Attribute Report Example 1 Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_scenes_management_command_missing.txt Example of an AttributeReportIB containing AttributeDataIB with a specific attribute path and data. ```log [1758019979.223] [98947:37460789:chip] [DMG] AttributeReportIB = { AttributeDataIB = { DataVersion = 0xc9af32ee, AttributePathIB = { Endpoint = 0x0, Cluster = 0x28, Attribute = 0x0000_000A, } Data = "v2.5.2 0.10.0-matter" (20 chars), }, }, ``` -------------------------------- ### Data Structure Example Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/1_5_missing_lighting_feature_wildcards.txt An example of a data structure, potentially representing a list of attributes or values within the Matter framework. ```c Data = [ 0x0 = [ 0x4d, 0x61, 0x68, 0x65, 0x73, 0x68, ] 0x1 = true, ], ], ``` -------------------------------- ### Run esp-matter-tools Web UI Source: https://context7.com/espressif/esp-matter-tools/llms.txt Launch the esp-matter-tools web application using Python's http.server module. Navigate to the UI directory and start the server on port 8000. ```bash # Navigate to the UI directory cd dmv_tool/ui # Start local HTTP server python3 -m http.server 8000 # Open http://localhost:8000 in your browser # Upload wildcard log files and validate conformance interactively ``` -------------------------------- ### Attribute Report Example 3 Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_scenes_management_command_missing.txt Example of an AttributeReportIB with an empty data field for attribute 0x0000_000C. ```log [1758019979.224] [98947:37460789:chip] [DMG] AttributeReportIB = { AttributeDataIB = { DataVersion = 0xc9af32ee, AttributePathIB = { Endpoint = 0x0, Cluster = 0x28, Attribute = 0x0000_000C, } Data = "" (0 chars), }, }, ``` -------------------------------- ### Attribute Report Example 4 Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_scenes_management_command_missing.txt Example of an AttributeReportIB with an empty data field for attribute 0x0000_000D. ```log [1758019979.224] [98947:37460789:chip] [DMG] AttributeReportIB = { AttributeDataIB = { DataVersion = 0xc9af32ee, AttributePathIB = { Endpoint = 0x0, Cluster = 0x28, Attribute = 0x0000_000D, } Data = "" (0 chars), }, }, ``` -------------------------------- ### Attribute Report Example 1 Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_missing_level_control_cluster.txt This snippet shows an example of an AttributeReportIB containing AttributeDataIB with a specific attribute path and data value. It's useful for understanding data reporting in Matter. ```log [1752139514.105] [177818:177820] [DMG] AttributeReportIB = { AttributeDataIB = { DataVersion = 0xa8a3f8b6, AttributePathIB = { Endpoint = 0x0, Cluster = 0x28, Attribute = 0x0000_0016, } Data = 1 (unsigned), }, }, ``` -------------------------------- ### AttributeReportIB with Specific Data Example Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_compliant_logs.txt This example shows an AttributeReportIB with AttributeDataIB, specifying Endpoint, Cluster, and Attribute. The Data field contains structured unsigned integer values. ```c #include "esp_matter_attribute.h" void app_main(void) { // ... other code ... AttributeReportIB = { .AttributeDataIB = { .DataVersion = 0xe42b9b99, .AttributePathIB = { .Endpoint = 0x0, .Cluster = 0x28, .Attribute = 0x0000_0013, }, .Data = { 0x0 = 3 (unsigned), 0x1 = 3 (unsigned), }, }, }; // ... other code ... } ``` -------------------------------- ### AttributeReportIB Structure Example Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_compliant_logs.txt This snippet illustrates the structure of an AttributeReportIB, which contains AttributeDataIB. It includes details like DataVersion and AttributePathIB. ```c #include "esp_matter_attribute.h" void app_main(void) { // ... other code ... AttributeReportIB = { .AttributeDataIB = { .DataVersion = 0xe42b9b99, .AttributePathIB = { .Endpoint = 0x0, .Cluster = 0x28, .Attribute = 0x0000_0012, }, .Data = "B8BB887EE100A30C" (16 chars), }, }; // ... other code ... } ``` -------------------------------- ### Attribute Report Example 4 Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/1_5_missing_lighting_feature_wildcards.txt Represents an AttributeReportIB with an array of unsigned integers. ```c #include "esp_matter_attribute_reporting.h" void example_function() { AttributeReportIB = { AttributeDataIB = { DataVersion = 0x357b6df9, AttributePathIB = { Endpoint = 0x1, Cluster = 0x6, Attribute = 0x0000_FFFB, }, Data = [ 65532 (unsigned), 65533 (unsigned), 0 (unsigned), 16384 (unsigned), 16385 (unsigned), 16386 (unsigned), 16387 (unsigned), 65531 (unsigned), 65529 (unsigned), 65528 (unsigned), ], }, }; } ``` -------------------------------- ### Attribute Report Example 3 Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/1_5_missing_lighting_feature_wildcards.txt Represents an AttributeReportIB with a NULL data value. ```c #include "esp_matter_attribute_reporting.h" void example_function() { AttributeReportIB = { AttributeDataIB = { DataVersion = 0x357b6df9, AttributePathIB = { Endpoint = 0x1, Cluster = 0x6, Attribute = 0x0000_4003, }, Data = NULL }, }; } ``` -------------------------------- ### Export Matter SDK Path Source: https://github.com/espressif/esp-matter-tools/blob/main/mfg_tool/README.md Export the Matter SDK path to simplify certificate and key paths for usage examples. This command assumes the SDK is located within the ESP-MATTER path. ```bash export MATTER_SDK_PATH=$ESP_MATTER_PATH/connectedhomeip/connectedhomeip ``` -------------------------------- ### AttributeReportIB Structure Example Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/1_5_missing_lighting_feature_wildcards.txt This snippet shows the structure of an AttributeReportIB, which encapsulates attribute data for reporting. It includes DataVersion and AttributePathIB. ```log [1773979821.214] [583910:583912] [DMG] AttributeReportIB = { AttributeDataIB = { DataVersion = 0xf908323d, AttributePathIB = { Endpoint = 0x0, Cluster = 0x36, Attribute = 0x0000_0000, } Data = [ 0xf6, 0x34, 0x58, 0x0d, 0x6d, 0x61, ] (6 bytes) }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xf908323d, AttributePathIB = { Endpoint = 0x0, Cluster = 0x36, Attribute = 0x0000_0001, } Data = 4 (unsigned), }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xf908323d, AttributePathIB = { Endpoint = 0x0, Cluster = 0x36, Attribute = 0x0000_0002, } Data = 3 (unsigned), }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xf908323d, AttributePathIB = { Endpoint = 0x0, Cluster = 0x36, Attribute = 0x0000_0003, } Data = 4 (unsigned), }, } ``` -------------------------------- ### Attribute Report Example Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_missing_feature_req_attribute.txt This snippet demonstrates an AttributeReportIB structure used for reporting attribute data in Matter. It includes details like DataVersion, AttributePathIB (Endpoint, Cluster, Attribute), and the reported Data. ```c AttributeReportIB = { AttributeDataIB = { DataVersion = 0x40f67ce7, AttributePathIB = { Endpoint = 0x0, Cluster = 0x2a, Attribute = 0x0000_FFFC, }
This is a sample of the code that is being documented.
``` -------------------------------- ### Attribute Report with Byte String Data Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_scenes_management_command_missing.txt Example of an AttributeReportIB reporting a byte string. This is useful for transmitting arbitrary binary data. ```c #[1758019977.979] [98947:37460789:chip] [DMG] Data = [ 0x45, 0x53, 0x50, 0x5f, 0x49, 0x6e, 0x64, 0x69, 0x61, ] (9 bytes) ``` -------------------------------- ### AttributeReportIB Structure Example 1 Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_missing_level_control_cluster.txt Represents an AttributeReportIB with a single AttributeDataIB. This structure is used for reporting attribute data, including its version and path. ```c # AttributeReportIB = { AttributeDataIB = { DataVersion = 0xac3b567f, AttributePathIB = { Endpoint = 0x0, Cluster = 0x3f, Attribute = 0x0000_0003 } Data = 3 (unsigned) }, ``` -------------------------------- ### Attribute Report with NULL Data Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_scenes_management_command_missing.txt Example of an AttributeReportIB where the attribute data is NULL. This indicates that the attribute has no current value. ```c #[1758019977.979] [98947:37460789:chip] [DMG] Data = NULL ``` -------------------------------- ### Attribute Report for List Attribute (Example 2) Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_compliant_logs.txt This snippet shows an AttributeReportIB reporting a list of unsigned integers for a specific attribute. It includes the DataVersion, AttributePathIB, and the reported list data. ```log [1756719618.548] [51774:5149697:chip] [DMG] AttributeReportIB = { AttributeDataIB = { DataVersion = 0x608a0e11, AttributePathIB = { Endpoint = 0x0, Cluster = 0x3f, Attribute = 0x0000_FFF9, } Data = [ 0 (unsigned), 1 (unsigned), 3 (unsigned), 4 (unsigned), ], }, }, ``` -------------------------------- ### AttributeReportIB with Basic Data Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_compliant_logs.txt Represents an AttributeReportIB containing attribute data for a specific path. This example shows data for cluster 0x2a on endpoint 0. ```c AttributeReportIB = { AttributeDataIB = { DataVersion = 0xe414ec14, AttributePathIB = { Endpoint = 0x0, Cluster = 0x2a, Attribute = 0x0000_FFFB, } Data = [ 65532 (unsigned), 0 (unsigned), 65533 (unsigned), 1 (unsigned), 2 (unsigned), 3 (unsigned), 65528 (unsigned), 65529 (unsigned), 65531 (unsigned), ], }, }; ``` -------------------------------- ### Attribute Report for List Attribute (Example 1) Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_compliant_logs.txt This snippet displays an AttributeReportIB for an attribute that reports a list of unsigned integers. It details the DataVersion, AttributePathIB, and the list of data values. ```log [1756719618.548] [51774:5149697:chip] [DMG] AttributeReportIB = { AttributeDataIB = { DataVersion = 0x608a0e11, AttributePathIB = { Endpoint = 0x0, Cluster = 0x3f, Attribute = 0x0000_FFF8, } Data = [ 2 (unsigned), 5 (unsigned), ], }, }, ``` -------------------------------- ### AttributeReportIB Structure Example Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_missing_feature_req_attribute.txt This snippet shows the structure of an AttributeReportIB, detailing attribute data, version, and path information. It is used for reporting attribute changes in Matter devices. ```c AttributeReportIB = { AttributeDataIB = { DataVersion = 0xa8a3f8b6, AttributePathIB = { Endpoint = 0x0, Cluster = 0x28, Attribute = 0x0000_0016, } Data = 1 (unsigned), }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xa8a3f8b6, AttributePathIB = { Endpoint = 0x0, Cluster = 0x28, Attribute = 0x0000_FFFD, } Data = 5 (unsigned), }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xa8a3f8b6, AttributePathIB = { Endpoint = 0x0, Cluster = 0x28, Attribute = 0x0000_0005, } Data = "" (0 chars), }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xa8a3f8b6, AttributePathIB = { Endpoint = 0x0, Cluster = 0x28, Attribute = 0x0000_FFF8, } Data = [ ], }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xa8a3f8b6, AttributePathIB = { Endpoint = 0x0, Cluster = 0x28, Attribute = 0x0000_FFF8, } Data = [ ], }, }, ``` -------------------------------- ### Attribute Report with Boolean Data Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_scenes_management_command_missing.txt Example of an AttributeReportIB containing AttributeDataIB with a boolean 'Data' field. This is used for reporting attribute changes. ```c #[1758019977.979] [98947:37460789:chip] [DMG] Data = true, ``` -------------------------------- ### Attribute Report with Another Reserved Attribute Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_scenes_management_command_missing.txt Another example of an attribute report for a reserved attribute, demonstrating a different attribute identifier within the same endpoint and cluster. ```c AttributeReportIB = { AttributeDataIB = { DataVersion = 0x37460bcf, AttributePathIB = { Endpoint = 0x1, Cluster = 0x62, Attribute = 0x0000_FFFD, } }, }, ``` -------------------------------- ### Attribute Report for List Attribute (Example 3) Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_compliant_logs.txt This snippet details an AttributeReportIB for an attribute reporting a list of unsigned integers. It includes the DataVersion, AttributePathIB, and the specific list of data values reported. ```log [1756719618.548] [51774:5149697:chip] [DMG] AttributeReportIB = { AttributeDataIB = { DataVersion = 0x608a0e11, AttributePathIB = { Endpoint = 0x0, Cluster = 0x3f, Attribute = 0x0000_FFFB, } Data = [ 65532 (unsigned), 65533 (unsigned), 0 (unsigned), 1 (unsigned), 2 (unsigned), 3 (unsigned), 65528 (unsigned), 65529 (unsigned), 65531 (unsigned), ], }, }, ``` -------------------------------- ### Attribute Report with Mapped Unsigned Integer Data Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/1_5_missing_lighting_feature_wildcards.txt This example shows an attribute report where the data is a map of unsigned integers, keyed by specific identifiers. It's useful for reporting structured data within a cluster. ```log [1773979821.078] [583910:583912] [DMG] AttributeReportIB = { AttributeDataIB = { DataVersion = 0x74bd6142, AttributePathIB = { Endpoint = 0x0, Cluster = 0x30, Attribute = 0x0000_0001, } Data = { 0x0 = 60 (unsigned), 0x1 = 900 (unsigned), }, }, }, ``` -------------------------------- ### Matter CHIP Attribute Report Log Example Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_scenes_management_command_missing.txt This snippet shows a typical debug log output for Matter CHIP attribute reports, illustrating the nested structure of "AttributeReportIB" and "AttributeDataIB". ```CHIP Log Format ], }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xd979dadc, AttributePathIB = { Endpoint = 0x0, Cluster = 0x30, Attribute = 0x0000_0000, } Data = 0 (unsigned), }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xd979dadc, AttributePathIB = { Endpoint = 0x0, Cluster = 0x30, Attribute = 0x0000_0001, } Data = { 0x0 = 60 (unsigned), 0x1 = 900 (unsigned), }, }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xd979dadc, AttributePathIB = { Endpoint = 0x0, Cluster = 0x30, Attribute = 0x0000_0002, } Data = 0 (unsigned), }, }, AttributeReportIB = { AttributeDataIB = { DataVersion = 0xd979dadc, AttributePathIB = { Endpoint = 0x0, Cluster = 0x30, Attribute = 0x0000_0003, } ``` -------------------------------- ### Matter Attribute Report Log Structure Source: https://github.com/espressif/esp-matter-tools/blob/main/dmv_tool/tests/test_data/wildcard_scenes_management_command_missing.txt These snippets show the format of AttributeReportIB messages in Matter debug logs, including the DataVersion, AttributePathIB (Endpoint, Cluster, Attribute), and the Data being reported. Each example demonstrates a report for a different attribute. ```Matter Log Format AttributeReportIB = { AttributeDataIB = { DataVersion = 0xfccd8c55, AttributePathIB = { Endpoint = 0x0, Cluster = 0x2a, Attribute = 0x0000_0001, } Data = true, }, }, ``` ```Matter Log Format AttributeReportIB = { AttributeDataIB = { DataVersion = 0xfccd8c55, AttributePathIB = { Endpoint = 0x0, Cluster = 0x2a, Attribute = 0x0000_0002, } Data = 0 (unsigned), }, }, ``` ```Matter Log Format AttributeReportIB = { AttributeDataIB = { DataVersion = 0xfccd8c55, AttributePathIB = { Endpoint = 0x0, Cluster = 0x2a, Attribute = 0x0000_0003, } Data = 0 (unsigned), }, }, ``` ```Matter Log Format AttributeReportIB = { AttributeDataIB = { DataVersion = 0xfccd8c55, AttributePathIB = { Endpoint = 0x0, Cluster = 0x2a, Attribute = 0x0000_FFFC, } Data = 0 (unsigned), }, }, ``` -------------------------------- ### Generate a Basic Factory Partition Source: https://github.com/espressif/esp-matter-tools/blob/main/mfg_tool/README.md Use this command to generate a factory partition with essential vendor and product details, including attestation and certification information. Ensure the MATTER_SDK_PATH environment variable is set correctly. ```bash esp-matter-mfg-tool -v 0xFFF2 -p 0x8001 --vendor-name "test vendor" \ --product-name "test product" --hw-ver 1 --hw-ver-str "harware version" --pai \ -k $MATTER_SDK_PATH/credentials/test/attestation/Chip-Test-PAI-FFF2-8001-Key.pem \ -c $MATTER_SDK_PATH/credentials/test/attestation/Chip-Test-PAI-FFF2-8001-Cert.pem \ -cd $MATTER_SDK_PATH/credentials/test/certification-declaration/Chip-Test-CD-FFF2-8001.der ``` -------------------------------- ### Configure app with idf.py menuconfig Source: https://github.com/espressif/esp-matter-tools/blob/main/mfg_tool/README.md Navigate to your application directory and open the project configuration menu using idf.py menuconfig to enable custom factory partition and device info providers. ```bash cd