Skip to content

Commit

Permalink
samples: matter: Update zap files and regenerate sources
Browse files Browse the repository at this point in the history
* Update zap files
* Regenerate sources

Signed-off-by: Adrian Gielniewski <[email protected]>
  • Loading branch information
adigie committed Nov 15, 2024
1 parent 27901b9 commit 067c44f
Show file tree
Hide file tree
Showing 31 changed files with 682 additions and 1,402 deletions.
53 changes: 10 additions & 43 deletions samples/matter/light_bulb/src/default_zap/light_bulb.zap
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"fileFormat": 2,
"featureLevel": 100,
"featureLevel": 103,
"creator": "zap",
"keyValuePairs": [
{
Expand All @@ -17,19 +17,20 @@
}
],
"package": [
{
"pathRelativity": "relativeToZap",
"path": "../../../../../../modules/lib/matter/src/app/zap-templates/app-templates.json",
"type": "gen-templates-json",
"version": "chip-v1"
},
{
"pathRelativity": "relativeToZap",
"path": "../../../../../../modules/lib/matter/src/app/zap-templates/zcl/zcl.json",
"type": "zcl-properties",
"category": "matter",
"version": 1,
"description": "Matter SDK ZCL data"
},
{
"pathRelativity": "relativeToZap",
"path": "../../../../../../modules/lib/matter/src/app/zap-templates/app-templates.json",
"type": "gen-templates-json",
"category": "matter",
"version": "chip-v1"
}
],
"endpointTypes": [
Expand Down Expand Up @@ -817,40 +818,6 @@
"isIncoming": 0,
"isEnabled": 1
}
],
"attributes": [
{
"name": "FeatureMap",
"code": 65532,
"mfgCode": null,
"side": "client",
"type": "bitmap32",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "0",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "ClusterRevision",
"code": 65533,
"mfgCode": null,
"side": "client",
"type": "int16u",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "1",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
}
]
},
{
Expand Down Expand Up @@ -3167,7 +3134,7 @@
]
},
{
"name": "WiFi Network Diagnostics",
"name": "Wi-Fi Network Diagnostics",
"code": 54,
"mfgCode": null,
"define": "WIFI_NETWORK_DIAGNOSTICS_CLUSTER",
Expand Down Expand Up @@ -5152,4 +5119,4 @@
"parentEndpointIdentifier": null
}
]
}
}
12 changes: 3 additions & 9 deletions samples/matter/light_bulb/src/default_zap/zap-generated/access.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,6 @@
/* Cluster: Level Control, Attribute: StartUpCurrentLevel, Privilege: view */ \
0x0000001F, /* Cluster: Access Control, Attribute: ACL, Privilege: administer */ \
0x0000001F, /* Cluster: Access Control, Attribute: Extension, Privilege: administer */ \
/* Cluster: Access Control, Attribute: SubjectsPerAccessControlEntry, Privilege: view */ \
/* Cluster: Access Control, Attribute: TargetsPerAccessControlEntry, Privilege: view */ \
/* Cluster: Access Control, Attribute: AccessControlEntriesPerFabric, Privilege: view */ \
/* Cluster: Basic Information, Attribute: NodeLabel, Privilege: view */ \
/* Cluster: Basic Information, Attribute: Location, Privilege: view */ \
/* Cluster: OTA Software Update Requestor, Attribute: DefaultOTAProviders, Privilege: view */ \
Expand All @@ -56,9 +53,6 @@
/* Cluster: Level Control, Attribute: StartUpCurrentLevel, Privilege: view */ \
0x00000000, /* Cluster: Access Control, Attribute: ACL, Privilege: administer */ \
0x00000001, /* Cluster: Access Control, Attribute: Extension, Privilege: administer */ \
/* Cluster: Access Control, Attribute: SubjectsPerAccessControlEntry, Privilege: view */ \
/* Cluster: Access Control, Attribute: TargetsPerAccessControlEntry, Privilege: view */ \
/* Cluster: Access Control, Attribute: AccessControlEntriesPerFabric, Privilege: view */ \
/* Cluster: Basic Information, Attribute: NodeLabel, Privilege: view */ \
/* Cluster: Basic Information, Attribute: Location, Privilege: view */ \
/* Cluster: OTA Software Update Requestor, Attribute: DefaultOTAProviders, Privilege: view */ \
Expand All @@ -79,9 +73,6 @@
/* Cluster: Level Control, Attribute: StartUpCurrentLevel, Privilege: view */ \
chip::Access::Privilege::kAdminister, /* Cluster: Access Control, Attribute: ACL, Privilege: administer */ \
chip::Access::Privilege::kAdminister, /* Cluster: Access Control, Attribute: Extension, Privilege: administer */ \
/* Cluster: Access Control, Attribute: SubjectsPerAccessControlEntry, Privilege: view */ \
/* Cluster: Access Control, Attribute: TargetsPerAccessControlEntry, Privilege: view */ \
/* Cluster: Access Control, Attribute: AccessControlEntriesPerFabric, Privilege: view */ \
/* Cluster: Basic Information, Attribute: NodeLabel, Privilege: view */ \
/* Cluster: Basic Information, Attribute: Location, Privilege: view */ \
/* Cluster: OTA Software Update Requestor, Attribute: DefaultOTAProviders, Privilege: view */ \
Expand Down Expand Up @@ -256,18 +247,21 @@
#define GENERATED_ACCESS_READ_EVENT__CLUSTER { \
0x0000001F, /* Cluster: Access Control, Event: AccessControlEntryChanged, Privilege: administer */ \
0x0000001F, /* Cluster: Access Control, Event: AccessControlExtensionChanged, Privilege: administer */ \
0x0000001F, /* Cluster: Access Control, Event: FabricRestrictionReviewUpdate, Privilege: administer */ \
}

// Parallel array data (cluster, *event*, privilege) for read event
#define GENERATED_ACCESS_READ_EVENT__EVENT { \
0x00000000, /* Cluster: Access Control, Event: AccessControlEntryChanged, Privilege: administer */ \
0x00000001, /* Cluster: Access Control, Event: AccessControlExtensionChanged, Privilege: administer */ \
0x00000002, /* Cluster: Access Control, Event: FabricRestrictionReviewUpdate, Privilege: administer */ \
}

// Parallel array data (cluster, event, *privilege*) for read event
#define GENERATED_ACCESS_READ_EVENT__PRIVILEGE { \
chip::Access::Privilege::kAdminister, /* Cluster: Access Control, Event: AccessControlEntryChanged, Privilege: administer */ \
chip::Access::Privilege::kAdminister, /* Cluster: Access Control, Event: AccessControlExtensionChanged, Privilege: administer */ \
chip::Access::Privilege::kAdminister, /* Cluster: Access Control, Event: FabricRestrictionReviewUpdate, Privilege: administer */ \
}

////////////////////////////////////////////////////////////////////////////////
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,16 +49,17 @@
#define GENERATED_DEFAULTS_COUNT (1)

// This is an array of EmberAfAttributeMinMaxValue structures.
#define GENERATED_MIN_MAX_DEFAULT_COUNT 2
#define GENERATED_MIN_MAX_DEFAULT_COUNT 3
#define GENERATED_MIN_MAX_DEFAULTS \
{ \
/* Endpoint: 1, Cluster: On/Off (server) */ \
{ (uint16_t)0xFF, (uint16_t)0x0, (uint16_t)0x2 }, /* StartUpOnOff */ \
\
/* Endpoint: 1, Cluster: Level Control (server) */ \
/* Endpoint: 1, Cluster: Level Control (server) */ \
{ (uint16_t)0x0, (uint16_t)0x0, (uint16_t)0x3 }, /* Options */ \
{ \
(uint16_t)0x0, (uint16_t)0x0, (uint16_t)0x3 \
} /* Options */ \
(uint16_t)0x32, (uint16_t)0x1, (uint16_t)0xFF \
} /* DefaultMoveRate */ \
}

// This is an array of EmberAfAttributeMetadata structures.
Expand Down Expand Up @@ -361,7 +362,7 @@
{ ZAP_SIMPLE_DEFAULT(0x000F), 0x0000FFFC, 4, ZAP_TYPE(BITMAP32), 0 }, /* FeatureMap */ \
{ ZAP_SIMPLE_DEFAULT(2), 0x0000FFFD, 2, ZAP_TYPE(INT16U), 0 }, /* ClusterRevision */ \
\
/* Endpoint: 0, Cluster: WiFi Network Diagnostics (server) */ \
/* Endpoint: 0, Cluster: Wi-Fi Network Diagnostics (server) */ \
{ ZAP_EMPTY_DEFAULT(), 0x00000000, 7, ZAP_TYPE(OCTET_STRING), \
ZAP_ATTRIBUTE_MASK(EXTERNAL_STORAGE) | ZAP_ATTRIBUTE_MASK(NULLABLE) }, /* BSSID */ \
{ ZAP_EMPTY_DEFAULT(), 0x00000001, 1, ZAP_TYPE(ENUM8), \
Expand Down Expand Up @@ -472,8 +473,9 @@
ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE) }, /* OnTransitionTime */ \
{ ZAP_EMPTY_DEFAULT(), 0x00000013, 2, ZAP_TYPE(INT16U), \
ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE) }, /* OffTransitionTime */ \
{ ZAP_SIMPLE_DEFAULT(50), 0x00000014, 1, ZAP_TYPE(INT8U), \
ZAP_ATTRIBUTE_MASK(WRITABLE) | ZAP_ATTRIBUTE_MASK(NULLABLE) }, /* DefaultMoveRate */ \
{ ZAP_MIN_MAX_DEFAULTS_INDEX(2), 0x00000014, 1, ZAP_TYPE(INT8U), \
ZAP_ATTRIBUTE_MASK(MIN_MAX) | ZAP_ATTRIBUTE_MASK(WRITABLE) | \
ZAP_ATTRIBUTE_MASK(NULLABLE) }, /* DefaultMoveRate */ \
{ ZAP_SIMPLE_DEFAULT(255), 0x00004000, 1, ZAP_TYPE(INT8U), \
ZAP_ATTRIBUTE_MASK(TOKENIZE) | ZAP_ATTRIBUTE_MASK(WRITABLE) | \
ZAP_ATTRIBUTE_MASK(NULLABLE) }, /* StartUpCurrentLevel */ \
Expand Down Expand Up @@ -806,7 +808,7 @@
.eventCount = 0, \
},\
{ \
/* Endpoint: 0, Cluster: WiFi Network Diagnostics (server) */ \
/* Endpoint: 0, Cluster: Wi-Fi Network Diagnostics (server) */ \
.clusterId = 0x00000036, \
.attributes = ZAP_ATTRIBUTE_INDEX(137), \
.attributeCount = 12, \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
#define MATTER_DM_PLUGIN_THREAD_NETWORK_DIAGNOSTICS_SERVER
#define MATTER_DM_PLUGIN_THREAD_NETWORK_DIAGNOSTICS

// Use this macro to check if the server side of the WiFi Network Diagnostics cluster is included
// Use this macro to check if the server side of the Wi-Fi Network Diagnostics cluster is included
#define ZCL_USING_WIFI_NETWORK_DIAGNOSTICS_CLUSTER_SERVER
#define MATTER_DM_PLUGIN_WI_FI_NETWORK_DIAGNOSTICS_SERVER
#define MATTER_DM_PLUGIN_WI_FI_NETWORK_DIAGNOSTICS
Expand Down
Loading

0 comments on commit 067c44f

Please sign in to comment.