-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Fabric-Sync] Initial version of fabric-sync example
- Loading branch information
1 parent
3a6c545
commit f23a1c3
Showing
10 changed files
with
6,866 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# Copyright (c) 2024 Project CHIP Authors | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
import("//build_overrides/build.gni") | ||
|
||
# The location of the build configuration file. | ||
buildconfig = "${build_root}/config/BUILDCONFIG.gn" | ||
|
||
# CHIP uses angle bracket includes. | ||
check_system_includes = true | ||
|
||
default_args = { | ||
import("//args.gni") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# Copyright (c) 2024 Project CHIP Authors | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
import("//build_overrides/build.gni") | ||
import("//build_overrides/chip.gni") | ||
import("${chip_root}/build/chip/tools.gni") | ||
import("${chip_root}/src/lib/lib.gni") | ||
|
||
assert(chip_build_tools) | ||
|
||
executable("fabric-sync") { | ||
cflags = [ "-Wconversion" ] | ||
|
||
include_dirs = [ | ||
".", | ||
"${chip_root}/src/lib", | ||
] | ||
|
||
sources = [ "main.cpp" ] | ||
|
||
deps = [ | ||
"${chip_root}/examples/fabric-sync/bridge:fabric-bridge-lib", | ||
"${chip_root}/examples/fabric-sync/bridge:fabric-bridge-zap", | ||
"${chip_root}/examples/platform/linux:app-main", | ||
"${chip_root}/src/lib", | ||
"${chip_root}/third_party/inipp", | ||
] | ||
|
||
output_dir = root_out_dir | ||
} | ||
|
||
group("default") { | ||
deps = [ ":fabric-sync" ] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# Copyright (c) 2024 Project CHIP Authors | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
import("//build_overrides/chip.gni") | ||
|
||
import("${chip_root}/config/standalone/args.gni") | ||
|
||
chip_device_project_config_include = "<CHIPProjectAppConfig.h>" | ||
chip_project_config_include = "<CHIPProjectAppConfig.h>" | ||
chip_system_project_config_include = "<SystemProjectConfig.h>" | ||
|
||
chip_project_config_include_dirs = | ||
[ "${chip_root}/examples/fabric-sync/bridge/include" ] | ||
chip_project_config_include_dirs += [ "${chip_root}/config/standalone" ] | ||
|
||
chip_build_libshell = true | ||
|
||
chip_enable_additional_data_advertising = true | ||
|
||
chip_enable_rotating_device_id = true | ||
|
||
chip_config_network_layer_ble = false | ||
|
||
matter_enable_tracing_support = true | ||
matter_log_json_payload_hex = true | ||
matter_log_json_payload_decode_full = true | ||
|
||
# Thread devices do not support WakeOnLan because their mac address is >48bit | ||
chip_enable_openthread = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# Copyright (c) 2024 Project CHIP Authors | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
import("//build_overrides/chip.gni") | ||
import("${chip_root}/src/app/chip_data_model.gni") | ||
import("${chip_root}/src/lib/lib.gni") | ||
|
||
config("config") { | ||
include_dirs = [ "include" ] | ||
} | ||
|
||
chip_data_model("fabric-bridge-zap") { | ||
zap_file = "fabric-bridge.zap" | ||
is_server = true | ||
cflags = [ "-DDYNAMIC_ENDPOINT_COUNT=16" ] | ||
} | ||
|
||
# This includes all the clusters that only exist on the dynamic endpoint. | ||
source_set("fabric-bridge-common") { | ||
public_configs = [ ":config" ] | ||
|
||
sources = [ | ||
"${chip_root}/src/app/clusters/ecosystem-information-server/ecosystem-information-server.cpp", | ||
"${chip_root}/src/app/clusters/ecosystem-information-server/ecosystem-information-server.h", | ||
] | ||
|
||
public_deps = [ ":fabric-bridge-zap" ] | ||
} | ||
|
||
source_set("fabric-bridge-lib") { | ||
public_configs = [ ":config" ] | ||
|
||
sources = [ "include/CHIPProjectAppConfig.h" ] | ||
|
||
deps = [ | ||
"${chip_root}/examples/fabric-sync/bridge:fabric-bridge-common", | ||
"${chip_root}/examples/platform/linux:app-main", | ||
"${chip_root}/src/lib", | ||
] | ||
} |
Oops, something went wrong.