Code Monkey home page Code Monkey logo

project-chip / connectedhomeip Goto Github PK

View Code? Open in Web Editor NEW
7.0K 192.0 1.8K 557.62 MB

Matter (formerly Project CHIP) creates more connections between more objects, simplifying development for manufacturers and increasing compatibility for consumers, guided by the Connectivity Standards Alliance.

Home Page: https://buildwithmatter.com

License: Apache License 2.0

Dockerfile 0.14% Shell 0.61% C 4.21% C++ 48.06% Emacs Lisp 0.01% Objective-C 2.94% Objective-C++ 1.90% Python 8.81% CMake 0.38% Java 14.44% JavaScript 0.01% ZAP 1.57% Tcl 0.01% Jinja 0.23% Kotlin 16.64% Swift 0.05%
standard internet-of-things iot chip connectedhomeip connected-devices connected-home build-with-matter matter connectivity-standards-alliance

connectedhomeip's People

Contributors

andy31415 avatar arkq avatar bzbarsky-apple avatar cecille avatar damian-nordic avatar dependabot[bot] avatar emargolis avatar erjiaqing avatar jepenven-silabs avatar jmartinez-silabs avatar kghost avatar kkasperczyk-no avatar kpschoedel avatar lpbeliveau-silabs avatar mkardous-silabs avatar mrjerryjohns avatar mspang avatar pan-apple avatar pankore avatar sagar-apple avatar sharadb-amazon avatar shubhamdp avatar tcarmelveilleux avatar tehampson avatar turon avatar vivien-apple avatar woody-apple avatar wqx6 avatar yufengwangca avatar yunhanw-google avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

connectedhomeip's Issues

Fix failing distcheck

Problem

Distcheck fails on CI and locally.

Proposed Solution

Figure out what this does and fix it.

Not all EFR32 platform source files are being built

Problem

#125 removed rules to build some source files in the EFR32 platform.

EFR32/NetworkProvisioningServerImpl.cpp
EFR32/ThreadStackManagerImpl.cpp	
EFR32/GroupKeyStoreImpl.cpp
EFR32/Entropy.cpp
EFR32/SoftwareUpdateManagerImpl.cpp
EFR32/ConfigurationManagerImpl.cpp

Removed from src/platform/Makefile.am

Proposed Solution

Determine which bits are needed and how to bring them in.

Fix OpenThread Dependencies for EFR32

Problem

#125 Removed OpenThread dependencies from efr32-chip.mk and in the platform code.
It also removed dependencies on missing SEGGER header files(ref: src/platform/EFR32/Logging.cpp) and so if a project adds EFR32_LOG_ENABLED to their CHIPProjectConfig.h the build will not work.

The missing SEGGER headers, for example, are part of OpenThread.

Proposed Solution

Figure out if OpenTread is a hard dependency for all EFR32 apps (followed the openweave demo example) and if not bring in the missing SEGGER dependencies and make sure EFR32_LOG_ENABLED can be set.

Device Onboarding

[SC&T] OOB Pairing and Onboarding

This is a high level umbrella issue tracking work needed to support device onboarding.
Some of the sub-tasks are

  • Initial device discovery (rendezvous) #128
  • Setup a secure channel using PAKE #130
  • Provision network credentials to accessory #131
  • Establish operational credentials with accessory #132

No APIs to support symmetric key based payload encryption available in CHIP

Problem

No APIs exist in CHIP to support symmetric key based payload encryption

Proposed Solution

We are going to use existing code in the open source HAP ADK to implement encrypting the payload that gets sent over the wire. This issue tracks porting over the existing symmetric key based encryption from HAP ADK. This does NOT deal with the topic of how those keys are obtained / exchanged in the first place.

Specifically we should pull the code in these files from https://github.com/apple/HomeKitADK

  1. PAL/Crypto/MbedTLS/HAPMbedTLS.c
  2. PAL/Crypto/OpenSSL/HAPOpenSSL.c
  3. PAL/HAPBase+Crypto.c
  4. HAP/HAPSession.c : Some of the methods like HAPSessionEncryptControlMessage and HAPSessionEncryptControlMessageWithAAD if not everything

Mock platforms

Problem

Platform library testing for EFR32 and nRF5 currently require the platforms' DKs to be installed.

Proposed Solution

  • build mocks for each of the supported platforms
  • add unit tests for the functionality that consume the mocks

Reenable TIME_SERVICE_TIME_SYNC

Problem

#104 disabled TIME_SERVICE_TIME_SYNC at

#ifndef CHIP_DEVICE_CONFIG_ENABLE_CHIP_TIME_SERVICE_TIME_SYNC

and

#define CHIP_DEVICE_CONFIG_ENABLE_CHIP_TIME_SERVICE_TIME_SYNC 0

#125 removed the TimeSync Service configuration from the EFR32 Platform Config.
Reference:

#define CHIP_DEVICE_CONFIG_ENABLE_CHIP_TIME_SERVICE_TIME_SYNC 0

Proposed Solution

Check if these need to be enabled. If required, enable and fix the associated issues.

Docker images live in developer-owned repositories

Problem

//integrations/docker/images/* directories build and push to developer orgs, should point to something owned by project-chip.

Proposed Solution

create a docker.io org
update build.sh(s)
update any resulting docker-based builds to pull from official repositories

Enable Coverity

We also use Coverity, which supports public, open source projects free of charge. Between LGTM, clang static analysis, and Coverity, there is a non-overlapping Venn diagram of issues caught.

Originally posted by @gerickson in #37 (comment)

Run clang-tidy locally

How do / can I run clang-tidy locally on my MacBook Pro? Is that mechanism different than what we use for CI?

Originally posted by @gerickson in #1

We should have a way to run clang-tidy locally

Improve BUILDING.md instructions on how to use autotools.

Problem

Could someone with experience update the BUILDING.md doc with workflow best practices?

  • how to build the entire source,
  • how to build a specific set of sub-folders / modules, add new source files,
  • run & debug unit tests,
  • run and analyze code coverage results,
  • run formatting checks, etc.

BLE Device name is hardcoded

Problem

BLEManagerImpl.cpp computes device name using FabricState.LocalNodeId(). This was removed (and hardcoded to 0) in #104 for nRF5 and in #125 for EFR32.

Proposed Solution

Identify the correct replacement for LocalNodeId and use that to compute device name.

Code reference:
nRF5 -

snprintf(devNameBuf, sizeof(devNameBuf), "%s%04" PRIX32,
CHIP_DEVICE_CONFIG_BLE_DEVICE_NAME_PREFIX,
(uint32_t)0);

EFR32 -
snprintf(mDeviceName, sizeof(mDeviceName), "%s%04" PRIX32, CHIP_DEVICE_CONFIG_BLE_DEVICE_NAME_PREFIX,
(uint32_t)0);

Handler in GenericSoftwareUpdateManager may need to be resurrected

Problem

#104 removed the following functions from GenericSoftwareUpdateManagerImpl.
SoftwareUpdateFailed
HandleStatusReport
HandleServiceBindingEvent
HandleResponse
OnKeyError
OnResponseTimeout

Proposed Solution

Evaluate if these functions are needed. If so, identify the replacement APIs for ExchangeContext, and Binding and reimplement these functions.

nlbuild-autotools is out of date

Problem

"Upstream" nlbuild-autotools has bug fixes, updates this project lacks

Proposed Solution

  • apply git subtree magic
  • document git subtree magic so that others may apply in future

Build instructions should have make instead of Makefile-Standalone

I tried the build instructions:

$ brew install make autoconf automake libtool
$ brew install llvm@9
$ git clean -fdx
$ ./bootstrap-configure
$ make -f Makefile-Standalone
# got an error at this point telling me to run make distclean
$ make distclean
$ make -f Makefile-Standalone
# Next I tried to run some tests (previous from Building.md)
$ cd src/setup_payload
$ make check
# got error: make: *** No rule to make target `check'. Stop.
# where 1-7 where run at top level directory

I then ran:

$ git clean -xdf
$ ./bootstrap-configure
$ make

And then make check worked

UserSelectedMode APIs are returning dummy values

Problem

#104 removed support for DeviceDescriptor. Due to this UserSelectedMode APIs in GenericConnectivityManagerImpl.h are returning dummy values.

Proposed Solution

Identify the replacement APIs for DeviceDescriptor, and reimplemented the following functions.
_IsUserSelectedModeActive
_SetUserSelectedMode
_GetUserSelectedModeTimeout
_SetUserSelectedModeTimeout

Master seems broken for me.

Summary: Master seems broken for me.

Steps to reproduce:

  1. clone repo
  2. cd into repo
  3. git clean -fdx
  4. ./bootstrap-configure
  5. make -f Makefile-Standalone

This is the error I am seeing -
checking whether make supports nested variables... yes
configure: error: source directory already configured; run "make distclean" there first
make: *** [build/x86_64-apple-darwin/config.status] Error 1

Build warning

Warning while compiling main build: https://github.com/project-chip/connectedhomeip/runs/499611869?check_suite_focus=true

../../third_party/lwip/repo/lwip/src/core/udp.c: In function ‘udp_sendto_if_src’:
63
../../third_party/lwip/repo/lwip/src/core/udp.c:869:26: warning: passing argument 2 of ‘netif_apply_pcb’ from incompatible pointer type [-Wincompatible-pointer-types]
64
   netif_apply_pcb(netif, pcb);
65
                          ^~~
66
In file included from ../../third_party/lwip/repo/lwip/src/include/lwip/udp.h:46:0,
67
                 from ../../third_party/lwip/repo/lwip/src/core/udp.c:52:
68
../../third_party/lwip/repo/lwip/src/include/lwip/netif.h:371:6: note: expected ‘struct ip_pcb *’ but argument is of type ‘struct udp_pcb *’
69
 void netif_apply_pcb(struct netif *netif, struct ip_pcb *pcb);
70
      ^~~~~~~~~~~~~~~
71

nRF5 platform makefile is not building all source code

Problem

The following files are not being built, as they are heavily dependent on removed code (as part of #104 )

ConfigurationManagerImpl.cpp
ThreadStackManagerImpl.cpp
GroupKeyStoreImpl.cpp
SoftwareUpdateManagerImpl.cpp
Entropy.cpp

Removed from src/platform/Makefile.am

Proposed Solution

Fix the code, and add to makefile.

bootstrap-configure doesn't work in ubuntu

Problem

developer@17af346013fa:~/connectedhomeip$ ./bootstrap-configure
./bootstrap-configure: 42: ./bootstrap-configure: pushd: not found

Proposed Solution

bootstrap incorrectly uses #!/bin/sh at the top, but it's using a bash capability. Needs to be changed to !#/bin/bash

Linux/Posix implementation of Device Layer

Problem

A new implementation of device layer for Linux/Posix platform is needed.

Proposed Solution

Implement the new device layer.

Tracking list for the solution [@turon]:

  • Addd initial PlatformMgr: select loop, entropy, time [PR #614]
  • Add ConfigurationManager and FileStore support [#738]
  • Add ConnectivityManager and WiFi support [#739]
  • Extend ConnectivityManager with Thread support [#740]
  • Add BleManager support for Linux (bluez) [#741]
  • Add BleManager for Darwin
  • Add support for process termination [#742]
  • Extend tests
  • Add example app

Fix EFR32 Build Support file dependencies

Problem

#125 removed the following library dependencies from efr32-chip.mk

- Removed: linking with warm
- Removed: linking with mincrypt
- Removed: linking with uECC

#125 also removed the following library dependencies and extra sources from efr32-app.mk

- Removed: linking with freertos
- Removed: References to linker scripts
- Removed: References to extra source files like $(EFR32_SDK_ROOT)/util/third_party/mbedtls/sl_crypto/src/trng.c

Proposed Solution

These are very likely required for any CHIP based app to actually work on the EFR32 platform. Figure out how to bring them back.

Enable travis-ci

Let's move to travis for build steps. Waiting on ability to enable it from the market place.

_GetQRCodeString() is not implemented

Problem

#104 removed support for DeviceDescriptor from ConfigurationManager. That in turn removed the implementation for _GetQRCodeString().

Proposed Solution

Identify the correct/new API that replaces DeviceDescriptor. Re-implement _GetQRCodeString using this API.

Update .gitignore and BuildConfig header

With the new automake based build system, each build leaves many untracked files in the tree.
It also overwrites the BuildConfig.h that's included in the tree. This file can most likely be removed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.