Skip to content

Commit

Permalink
Merge branch 'master' into topic/pucn_psoc6_release
Browse files Browse the repository at this point in the history
  • Loading branch information
andy31415 authored Jul 19, 2024
2 parents df38ed5 + d62f5a6 commit 5fb9563
Show file tree
Hide file tree
Showing 135 changed files with 2,739 additions and 1,524 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/chef.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ jobs:
if: github.actor != 'restyled-io[bot]'

container:
image: ghcr.io/project-chip/chip-build-telink:57
image: ghcr.io/project-chip/chip-build-telink:65
options: --user root

steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cirque.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
# need to run with privilege, which isn't supported by job.XXX.contaner
# https://github.com/actions/container-action/issues/2
# container:
# image: ghcr.io/project-chip/chip-build-cirque:54
# image: ghcr.io/project-chip/chip-build-cirque:<VERSION_HERE>
# volumes:
# - "/tmp:/tmp"
# - "/dev/pts:/dev/pts"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/doxygen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ jobs:

runs-on: ubuntu-latest
container:
image: ghcr.io/project-chip/chip-build-doxygen:54
image: ghcr.io/project-chip/chip-build-doxygen:65

if: github.actor != 'restyled-io[bot]'

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/examples-linux-arm.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
if: github.actor != 'restyled-io[bot]'

container:
image: ghcr.io/project-chip/chip-build-crosscompile:54
image: ghcr.io/project-chip/chip-build-crosscompile:65
volumes:
- "/tmp/bloat_reports:/tmp/bloat_reports"

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/java-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
runs-on: ubuntu-latest

container:
image: ghcr.io/project-chip/chip-build-java:54
image: ghcr.io/project-chip/chip-build-java:65
options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0
net.ipv4.conf.all.forwarding=0 net.ipv6.conf.all.forwarding=0"

Expand Down
4 changes: 2 additions & 2 deletions config/telink/app/bootloader_usb.conf
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@

# USB DFU configuration
CONFIG_USB_DFU_WILL_DETACH=n
CONFIG_BOOT_USB_DFU_GPIO=y
CONFIG_MCUBOOT_INDICATION_LED=y
CONFIG_BOOT_USB_DFU_GPIO=n
CONFIG_MCUBOOT_INDICATION_LED=n
Original file line number Diff line number Diff line change
Expand Up @@ -8476,6 +8476,8 @@ endpoint 1 {
server cluster EnergyEvseMode {
callback attribute supportedModes;
callback attribute currentMode;
ram attribute startUpMode;
ram attribute onMode;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
Expand All @@ -8490,6 +8492,8 @@ endpoint 1 {
server cluster DeviceEnergyManagementMode {
callback attribute supportedModes;
callback attribute currentMode;
ram attribute startUpMode;
ram attribute onMode;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
Expand Down
78 changes: 71 additions & 7 deletions examples/all-clusters-app/all-clusters-common/all-clusters-app.zap
Original file line number Diff line number Diff line change
Expand Up @@ -17,20 +17,20 @@
}
],
"package": [
{
"pathRelativity": "relativeToZap",
"path": "../../../src/app/zap-templates/app-templates.json",
"type": "gen-templates-json",
"category": "matter",
"version": "chip-v1"
},
{
"pathRelativity": "relativeToZap",
"path": "../../../src/app/zap-templates/zcl/zcl-with-test-extensions.json",
"type": "zcl-properties",
"category": "matter",
"version": 1,
"description": "Matter SDK ZCL data with some extensions"
},
{
"pathRelativity": "relativeToZap",
"path": "../../../src/app/zap-templates/app-templates.json",
"type": "gen-templates-json",
"category": "matter",
"version": "chip-v1"
}
],
"endpointTypes": [
Expand Down Expand Up @@ -14615,6 +14615,38 @@
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "StartUpMode",
"code": 2,
"mfgCode": null,
"side": "server",
"type": "int8u",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "OnMode",
"code": 3,
"mfgCode": null,
"side": "server",
"type": "int8u",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "GeneratedCommandList",
"code": 65528,
Expand Down Expand Up @@ -14772,6 +14804,38 @@
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "StartUpMode",
"code": 2,
"mfgCode": null,
"side": "server",
"type": "int8u",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "OnMode",
"code": 3,
"mfgCode": null,
"side": "server",
"type": "int8u",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "GeneratedCommandList",
"code": 65528,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2331,6 +2331,8 @@ endpoint 1 {
server cluster EnergyEvseMode {
callback attribute supportedModes;
callback attribute currentMode;
ram attribute startUpMode;
ram attribute onMode;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
Expand All @@ -2345,6 +2347,8 @@ endpoint 1 {
server cluster DeviceEnergyManagementMode {
callback attribute supportedModes;
callback attribute currentMode;
ram attribute startUpMode;
ram attribute onMode;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4679,6 +4679,38 @@
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "StartUpMode",
"code": 2,
"mfgCode": null,
"side": "server",
"type": "int8u",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "OnMode",
"code": 3,
"mfgCode": null,
"side": "server",
"type": "int8u",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "GeneratedCommandList",
"code": 65528,
Expand Down Expand Up @@ -4836,6 +4868,38 @@
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "StartUpMode",
"code": 2,
"mfgCode": null,
"side": "server",
"type": "int8u",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "OnMode",
"code": 3,
"mfgCode": null,
"side": "server",
"type": "int8u",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "GeneratedCommandList",
"code": 65528,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ using namespace chip;
using namespace chip::app;
using namespace chip::app::Clusters;
using namespace chip::app::Clusters::OperationalState;
using namespace chip::app::Clusters::RvcOperationalState;

CHIP_ERROR GenericOperationalStateDelegateImpl::GetOperationalStateAtIndex(size_t index, GenericOperationalState & operationalState)
{
Expand Down
11 changes: 11 additions & 0 deletions examples/network-manager-app/linux/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,14 @@
*/

#include <AppMain.h>
#include <app/clusters/thread-network-directory-server/thread-network-directory-server.h>
#include <app/clusters/wifi-network-management-server/wifi-network-management-server.h>
#include <lib/core/CHIPSafeCasts.h>
#include <lib/support/CodeUtils.h>
#include <lib/support/Span.h>

#include <optional>

using namespace chip;
using namespace chip::app;
using namespace chip::app::Clusters;
Expand All @@ -32,6 +36,13 @@ ByteSpan ByteSpanFromCharSpan(CharSpan span)
return ByteSpan(Uint8::from_const_char(span.data()), span.size());
}

std::optional<DefaultThreadNetworkDirectoryServer> gThreadNetworkDirectoryServer;
void emberAfThreadNetworkDirectoryClusterInitCallback(chip::EndpointId endpoint)
{
VerifyOrDie(!gThreadNetworkDirectoryServer);
gThreadNetworkDirectoryServer.emplace(endpoint).Init();
}

int main(int argc, char * argv[])
{
if (ChipLinuxAppInit(argc, argv) != 0)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1195,6 +1195,51 @@ cluster WiFiNetworkManagement = 1105 {
command access(invoke: administer) NetworkPassphraseRequest(): NetworkPassphraseResponse = 0;
}

/** Manages the names and credentials of Thread networks visible to the user. */
cluster ThreadNetworkDirectory = 1107 {
revision 1;

struct ThreadNetworkStruct {
octet_string<8> extendedPanID = 0;
char_string<16> networkName = 1;
int16u channel = 2;
int64u activeTimestamp = 3;
}

attribute access(read: manage, write: manage) nullable octet_string<8> preferredExtendedPanID = 0;
readonly attribute access(read: operate) ThreadNetworkStruct threadNetworks[] = 1;
readonly attribute int8u threadNetworkTableSize = 2;
readonly attribute command_id generatedCommandList[] = 65528;
readonly attribute command_id acceptedCommandList[] = 65529;
readonly attribute event_id eventList[] = 65530;
readonly attribute attrib_id attributeList[] = 65531;
readonly attribute bitmap32 featureMap = 65532;
readonly attribute int16u clusterRevision = 65533;

request struct AddNetworkRequest {
octet_string<254> operationalDataset = 0;
}

request struct RemoveNetworkRequest {
octet_string<8> extendedPanID = 0;
}

request struct GetOperationalDatasetRequest {
octet_string<8> extendedPanID = 0;
}

response struct OperationalDatasetResponse = 3 {
octet_string<254> operationalDataset = 0;
}

/** Adds an entry to the ThreadNetworks list. */
timed command access(invoke: manage) AddNetwork(AddNetworkRequest): DefaultSuccess = 0;
/** Removes an entry from the ThreadNetworks list. */
timed command access(invoke: manage) RemoveNetwork(RemoveNetworkRequest): DefaultSuccess = 1;
/** Retrieves a Thread Operational Dataset from the ThreadNetworks list. */
timed command GetOperationalDataset(GetOperationalDatasetRequest): OperationalDatasetResponse = 2;
}

endpoint 0 {
device type ma_rootdevice = 22, version 1;

Expand Down Expand Up @@ -1473,6 +1518,23 @@ endpoint 1 {
handle command NetworkPassphraseRequest;
handle command NetworkPassphraseResponse;
}

server cluster ThreadNetworkDirectory {
callback attribute preferredExtendedPanID;
callback attribute threadNetworks;
callback attribute threadNetworkTableSize;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
callback attribute attributeList;
ram attribute featureMap default = 0;
ram attribute clusterRevision default = 1;

handle command AddNetwork;
handle command RemoveNetwork;
handle command GetOperationalDataset;
handle command OperationalDatasetResponse;
}
}


Loading

0 comments on commit 5fb9563

Please sign in to comment.