Closed markusp00 closed 1 year ago
Zap has to be matched exactly to the CHIP release. CHIP 1.0.0.2 works with this specfic zap-cli (other releases won't work) https://github.com/project-chip/zap/releases/tag/v2022.12.20-nightly
Zap is very painful to use, I would suggest using the non-zap, esp-matter version of the lighting app.
@markusp00 As mentioned by @jonsmirl the ZAP should match the v1.0.0.2 tag of upstream connectedhomeip. Please give it a try and update in case of any issues
I have now tried multiple releases of ZAP without any luck. I encounter the same problems as the other members of my project group. We have decided to abandon ZAP and instead use the non-zap esp-matter platform.
Even i am facing the same error @dhrishi while building the lighning app when i enter the command idf.py build i am not able to build . I am getting these logs .
einfochips@PUNECPU0517:~/Desktop/matter/connectedhomeip/examples/lighting-app/esp32$ idf.py build
Executing action: all (aliases: build)
Running ninja in directory /home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/build
Executing "ninja all"...
[1/41] Performing build step for 'chip_gn'
ninja: no work to do.
[2/39] Performing build step for 'bootloader'
[1/1] cd /home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/build/bootloader/esp-idf/esptool_py && /home/einfochips/Desktop/matter/connectedhomeip/.environment/pigweed-venv/bin/python /home/einfochips/Desktop/ESP32/esp-idf/components/partition_table/check_sizes.py --offset 0x8000 bootloader 0x1000 /home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/build/bootloader/bootloader.bin
Bootloader binary size 0x6330 bytes. 0xcd0 bytes (11%) free.
[4/37] Building CXX object esp-idf/main/CMakeFiles/idf_main.dir/__/third_party/connectedhomeip/src/app/util/attribute-storage.cpp.obj
FAILED: esp-idf/main/CMakeFiles/idf_main.dir//third_party/connectedhomeip/src/app/util/attribute-storage.cpp.obj
/home/einfochips/.espressif/tools/xtensa-esp32-elf/esp-2021r2-patch3-8.4.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-g++ -DHAVE_CONFIG_H -DMBEDTLS_CONFIG_FILE=\"mbedtls/esp_config.h\" -DUNITY_INCLUDE_CONFIG_H -DWITH_POSIX -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/build/config -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/third_party/connectedhomeip/zzz_generated/lighting-app -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/third_party/connectedhomeip/examples/providers -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/third_party/connectedhomeip/examples/lighting-app/lighting-common/include -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/main/include -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/third_party/connectedhomeip/examples/platform/esp32 -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/build/gen/app-codegen/cpp-app -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/build/gen/app-zapgen/zapgen/app-templates -I/home/einfochips/Desktop/ESP32/esp-idf/components/newlib/platform_include -I/home/einfochips/Desktop/ESP32/esp-idf/components/freertos/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/freertos/include/esp_additions/freertos -I/home/einfochips/Desktop/ESP32/esp-idf/components/freertos/port/xtensa/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/freertos/include/esp_additions -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_hw_support/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_hw_support/include/soc -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_hw_support/include/soc/esp32 -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_hw_support/port/esp32/. -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_hw_support/port/esp32/private_include -I/home/einfochips/Desktop/ESP32/esp-idf/components/heap/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/log/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/lwip/include/apps -I/home/einfochips/Desktop/ESP32/esp-idf/components/lwip/include/apps/sntp -I/home/einfochips/Desktop/ESP32/esp-idf/components/lwip/lwip/src/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/lwip/port/esp32/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/lwip/port/esp32/include/arch -I/home/einfochips/Desktop/ESP32/esp-idf/components/soc/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/soc/esp32/. -I/home/einfochips/Desktop/ESP32/esp-idf/components/soc/esp32/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/hal/esp32/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/hal/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/hal/platform_port/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_rom/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_rom/include/esp32 -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_rom/esp32 -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_common/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_system/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_system/port/soc -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_system/port/public_compat -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp32/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/xtensa/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/xtensa/esp32/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/driver/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/driver/esp32/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_pm/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_ringbuf/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/efuse/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/efuse/esp32/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/vfs/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_wifi/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_event/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_netif/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_eth/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/tcpip_adapter/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_phy/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_phy/esp32/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_ipc/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/app_trace/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_timer/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/app_update/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/spi_flash/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bootloader_support/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/asio/asio/asio/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/asio/port/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/common/osi/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/include/esp32/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/common/api/include/api -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/common/btc/profile/esp/blufi/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/common/btc/profile/esp/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/porting/nimble/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/port/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/services/ans/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/services/bas/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/services/dis/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/services/gap/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/services/gatt/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/services/ias/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/services/ipss/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/services/lls/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/services/tps/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/util/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/store/ram/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/nimble/host/store/config/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/nimble/porting/npl/freertos/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/bt/host/nimble/esp-hci/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/nvs_flash/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/mbedtls/port/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/mbedtls/mbedtls/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/mbedtls/esp_crt_bundle/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/cbor/port/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/cmock/CMock/src -I/home/einfochips/Desktop/ESP32/esp-idf/components/unity/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/unity/unity/src -I/home/einfochips/Desktop/ESP32/esp-idf/components/coap/port/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/coap/libcoap/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/console -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp-tls -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp-tls/esp-tls-crypto -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_adc_cal/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_gdbstub/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_gdbstub/xtensa -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_gdbstub/esp32 -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_hid/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_http_client/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/nghttp/port/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/nghttp/nghttp2/lib/includes -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_http_server/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_https_ota/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_lcd/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_lcd/interface -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_local_ctrl/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/protocomm/include/common -I/home/einfochips/Desktop/ESP32/esp-idf/components/protocomm/include/security -I/home/einfochips/Desktop/ESP32/esp-idf/components/protocomm/include/transports -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_serial_slave_link/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/sdmmc/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/esp_websocket_client/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/tcp_transport/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/espcoredump/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/espcoredump/include/port/xtensa -I/home/einfochips/Desktop/ESP32/esp-idf/components/expat/expat/expat/lib -I/home/einfochips/Desktop/ESP32/esp-idf/components/expat/port/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/fatfs/diskio -I/home/einfochips/Desktop/ESP32/esp-idf/components/fatfs/vfs -I/home/einfochips/Desktop/ESP32/esp-idf/components/fatfs/src -I/home/einfochips/Desktop/ESP32/esp-idf/components/wear_levelling/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/freemodbus/common/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/idf_test/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/idf_test/include/esp32 -I/home/einfochips/Desktop/ESP32/esp-idf/components/ieee802154/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/jsmn/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/json/cJSON -I/home/einfochips/Desktop/ESP32/esp-idf/components/libsodium/libsodium/src/libsodium/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/libsodium/port_include -I/home/einfochips/Desktop/ESP32/esp-idf/components/mdns/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/mqtt/esp-mqtt/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/openssl/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/perfmon/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/protobuf-c/protobuf-c -I/home/einfochips/Desktop/ESP32/esp-idf/components/pthread/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/spiffs/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/ulp/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/wifi_provisioning/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/wpa_supplicant/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/wpa_supplicant/port/include -I/home/einfochips/Desktop/ESP32/esp-idf/components/wpa_supplicant/esp_supplicant/include -I/home/einfochips/Desktop/matter/connectedhomeip/src/platform/ESP32 -I/home/einfochips/Desktop/matter/connectedhomeip/src/platform/OpenThread -I/home/einfochips/Desktop/matter/connectedhomeip/src/include -I/home/einfochips/Desktop/matter/connectedhomeip/src/lib -I/home/einfochips/Desktop/matter/connectedhomeip/src -I/home/einfochips/Desktop/matter/connectedhomeip/zzz_generated/app-common -I/home/einfochips/Desktop/matter/connectedhomeip/examples/platform/esp32 -I/home/einfochips/Desktop/matter/connectedhomeip/third_party/nlassert/repo/include -I/home/einfochips/Desktop/matter/connectedhomeip/third_party/nlio/repo/include -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/build/esp-idf/chip/src/include -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/build/esp-idf/chip/include -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/build/esp-idf/chip/gen/include -I/home/einfochips/Desktop/matter/connectedhomeip/config/esp32 -I/home/einfochips/Desktop/matter/connectedhomeip/config/esp32/../.. -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/third_party/connectedhomeip/config/esp32/components/esp32_mbedtls -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/third_party/connectedhomeip/examples/common/QRCode/repo/c -I/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/managed_components/espressifled_strip/include -mlongcalls -Wno-frame-address -ffunction-sections -fdata-sections -Wall -Werror=all -Wno-error=unused-function -Wno-error=unused-variable -Wno-error=deprecated-declarations -Wextra -Wno-unused-parameter -Wno-sign-compare -ggdb -Og -fmacro-prefix-map=/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32=. -fmacro-prefix-map=/home/einfochips/Desktop/ESP32/esp-idf=IDF -fstrict-volatile-bitfields -Wno-error=unused-but-set-variable -fno-jump-tables -fno-tree-switch-conversion -Wno-format-nonliteral -Wno-format-security -Wno-error=maybe-uninitialized -Wno-error=uninitialized -std=gnu++11 -fno-exceptions -fno-rtti -std=gnu++17 -Os -DCHIP_HAVE_CONFIG_H -D_GNU_SOURCE -DIDF_VER=\"v4.4.2\" -DESP_PLATFORM -D_POSIX_READER_WRITER_LOCKS "-DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER=<lib/address_resolve/AddressResolve_DefaultImpl.h>" -std=gnu++17 -MD -MT esp-idf/main/CMakeFiles/idf_main.dir/__/third_party/connectedhomeip/src/app/util/attribute-storage.cpp.obj -MF esp-idf/main/CMakeFiles/idf_main.dir//third_party/connectedhomeip/src/app/util/attribute-storage.cpp.obj.d -o esp-idf/main/CMakeFiles/__idf_main.dir//third_party/connectedhomeip/src/app/util/attribute-storage.cpp.obj -c /home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/third_party/connectedhomeip/src/app/util/attribute-storage.cpp
In file included from /home/einfochips/Desktop/matter/connectedhomeip/src/app/util/config.h:31,
from /home/einfochips/Desktop/matter/connectedhomeip/src/app/util/af.h:23,
from /home/einfochips/Desktop/matter/connectedhomeip/src/app/util/common.h:21,
from /home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/third_party/connectedhomeip/src/app/util/attribute-storage.cpp:18:
/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/build/gen/app-zapgen/zapgen/app-templates/zap-generated/endpoint_config.h:421:1: error: braces around scalar initializer for type 'EmberAfAttributeMask' {aka 'unsigned char'}
}
^
/home/einfochips/Desktop/matter/connectedhomeip/examples/lighting-app/esp32/third_party/connectedhomeip/src/app/util/attribute-storage.cpp:85:71: note: in expansion of macro 'GENERATED_ATTRIBUTES'
constexpr const EmberAfAttributeMetadata generatedAttributes[] = GENERATED_ATTRIBUTES;
^~~~~~~~
[9/37] Building CXX object esp-idf/main/CMakeFiles/__idf_main.dir/__/third_party/connectedhomeip/src/app/clusters/general-diagnostics-server/general-diagnostics-server.cpp.obj
ninja: build stopped: subcommand failed.
ninja failed with exit code 1
I am unable to modify the zap_light example using the zap-tool. I suspect it is caused by a wrong version of some software.
This is my current setup:
Steps to replicate:
./scripts/tools/zap/run_zaptool.sh
Results: