Skip to content

Commit

Permalink
Initial demo work
Browse files Browse the repository at this point in the history
  • Loading branch information
robertfarnum committed Sep 4, 2024
1 parent 5d9b145 commit 82d9e28
Show file tree
Hide file tree
Showing 42 changed files with 443 additions and 132 deletions.
104 changes: 0 additions & 104 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -93,93 +93,13 @@
url = https://github.com/ARMmbed/mbed-os-cypress-capsense-button.git
branch = main
platforms = mbed
[submodule "p6/abstraction-rtos"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/abstraction-rtos
url = https://github.com/Infineon/abstraction-rtos
platforms = infineon
[submodule "p6/btstack"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/btstack
url = https://github.com/Infineon/btstack
platforms = infineon
[submodule "p6/clib-support"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/clib-support
url = https://github.com/Infineon/clib-support
platforms = infineon
[submodule "p6/connectivity-utilities"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/connectivity-utilities
url = https://github.com/Infineon/connectivity-utilities
platforms = infineon
[submodule "p6/core-lib"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/core-lib
url = https://github.com/Infineon/core-lib
platforms = infineon
[submodule "p6/core-make"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/core-make
url = https://github.com/Infineon/core-make
platforms = infineon
[submodule "p6/kv-store"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/kv-store
url = https://github.com/Infineon/kv-store
platforms = infineon
[submodule "p6/mtb-hal-cat1"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/mtb-hal-cat1
url = https://github.com/Infineon/mtb-hal-cat1
platforms = infineon
[submodule "p6/mtb-pdl-cat1"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/mtb-pdl-cat1
url = https://github.com/Infineon/mtb-pdl-cat1
platforms = infineon
[submodule "p6/whd-bsp-integration"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/whd-bsp-integration
url = https://github.com/Infineon/whd-bsp-integration
platforms = infineon
[submodule "p6/wifi-connection-manager"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/wifi-connection-manager
url = https://github.com/Infineon/wifi-connection-manager
platforms = infineon
[submodule "p6/wifi-host-driver"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/wifi-host-driver
url = https://github.com/Infineon/wifi-host-driver
platforms = infineon
[submodule "p6/TARGET_CY8CKIT-062S2-43012"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/TARGET_CY8CKIT-062S2-43012
url = https://github.com/Infineon/TARGET_CY8CKIT-062S2-43012
platforms = infineon
[submodule "p6/freertos"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/freertos
url = https://github.com/Infineon/freertos
platforms = infineon
[submodule "p6/retarget-io"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/retarget-io
url = https://github.com/Infineon/retarget-io
platforms = infineon
[submodule "p6/mbedtls"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/mbedtls
url = https://github.com/ARMmbed/mbedtls
platforms = infineon
[submodule "p6/secure-sockets"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/secure-sockets
url = https://github.com/Infineon/secure-sockets
platforms = infineon
[submodule "p6/recipe-make-cat1a"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/recipe-make-cat1a
url = https://github.com/Infineon/recipe-make-cat1a
platforms = infineon
[submodule "p6/lwip"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/lwip
url = https://github.com/lwip-tcpip/lwip.git
platforms = infineon
[submodule "third_party/jsoncpp/repo"]
path = third_party/jsoncpp/repo
url = https://github.com/open-source-parsers/jsoncpp.git
[submodule "third_party/mbed-mcu-boot/repo"]
path = third_party/mbed-mcu-boot/repo
url = https://github.com/ATmobica/mcuboot.git
platforms = mbed
[submodule "p6/serial-flash"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/serial-flash
url = https://github.com/Infineon/serial-flash
platforms = infineon
[submodule "infineon/matter-wpan-sdk"]
path = third_party/infineon/repos/matter-wpan-sdk
url = https://github.com/Infineon/matter-wpan-sdk.git
Expand Down Expand Up @@ -305,30 +225,6 @@
url = https://github.com/NXP/nxp_matter_support.git
branch = master
platforms = nxp
[submodule "third_party/infineon/psoc6/psoc6_sdk/libs/btstack-integration"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/btstack-integration
url = https://github.com/Infineon/btstack-integration.git
platforms = infineon
[submodule "third_party/infineon/psoc6/psoc6_sdk/libs/cat1cm0p"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/cat1cm0p
url = https://github.com/Infineon/cat1cm0p.git
platforms = infineon
[submodule "third_party/infineon/psoc6/psoc6_sdk/libs/cmsis"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/cmsis
url = https://github.com/Infineon/cmsis.git
platforms = infineon
[submodule "third_party/infineon/psoc6/psoc6_sdk/libs/ota-bootloader-abstraction"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/ota-bootloader-abstraction
url = https://github.com/Infineon/ota-bootloader-abstraction.git
platforms = infineon
[submodule "third_party/infineon/psoc6/psoc6_sdk/libs/ota-update"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/ota-update
url = https://github.com/Infineon/ota-update.git
platforms = infineon
[submodule "third_party/infineon/psoc6/psoc6_sdk/libs/lwip-network-interface-integration"]
path = third_party/infineon/psoc6/psoc6_sdk/libs/lwip-network-interface-integration
url = https://github.com/Infineon/lwip-network-interface-integration.git
platforms = infineon
[submodule "third_party/abseil-cpp/src"]
path = third_party/abseil-cpp/src
url = https://github.com/abseil/abseil-cpp.git
Expand Down
25 changes: 25 additions & 0 deletions examples/app-library/linux/.gn
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Copyright (c) 2020 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")
}
16 changes: 16 additions & 0 deletions examples/app-library/linux/AppLibrary.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#include "AppMain.h"

namespace {
constexpr chip::EndpointId kNetworkCommissioningEndpointSecondary = 0xFFFE;
} // anonymous namespace

void ApplicationInit() {}

void ApplicationShutdown() {}

int LIB_StartMatterApp(int argc, char ** argv)
{
VerifyOrReturnValue(ChipLinuxAppInit(argc, argv) == 0, -1);
ChipLinuxAppMainLoop();
return -0;
}
38 changes: 38 additions & 0 deletions examples/app-library/linux/BUILD.gn
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Copyright (c) 2020 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")

shared_library("app-library") {
sources = [ "AppLibrary.cpp" ]

deps = [
"${chip_root}/examples/network-manager-app/network-manager-common",
"${chip_root}/examples/platform/linux:app-main",
"${chip_root}/src/lib",
]

include_dirs = [ "include" ]

output_dir = root_out_dir
}

group("linux") {
deps = [ ":app-library" ]
}

group("default") {
deps = [ ":linux" ]
}
23 changes: 23 additions & 0 deletions examples/app-library/linux/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#
# Copyright (c) 2020 Project CHIP Authors
# All rights reserved.
#
# 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.
#

FROM generic_node_image
RUN apt-get install -y libglib2.0
COPY out/debug/chip-all-clusters-app /usr/bin/
COPY entrypoint.sh /

ENTRYPOINT ["/entrypoint.sh", "server"]
11 changes: 11 additions & 0 deletions examples/app-library/linux/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
libmatter.so: matter-bridge.cpp
g++ \
-I/workspaces/connectedhomeip/third_party/nlio/repo/include \
-I/workspaces/connectedhomeip/third_party/nlassert/repo/include \
-I/workspaces/connectedhomeip/zzz_generated/app-common \
-I/workspaces/connectedhomeip/out/linux/gen/include \
-I/workspaces/connectedhomeip//src/include \
-I../../platform/linux \
-I../../../src -o \
-o libmatter.so matter-bridge.cpp -lCHIP.so \
-std=c++17 -O3 -Wall -Wextra -fPIC -shared
Loading

0 comments on commit 82d9e28

Please sign in to comment.