Skip to content

Commit

Permalink
Ensure all commands are generated for client cluster definitions in .…
Browse files Browse the repository at this point in the history
…matter IDL files (#25853)

* Generate all client-side commands and structures. This requires zap updates after project-chip/zap#981

* ZAP regen all

* Use zap 2023.03.27 to pick up clusterName and responseName access

* Update minimum zap version

* Start using zcl_commands_source_client instead of chip_cluster_responses

* Update invoke callbacks too to use updated stateless loop methods

* Noop update: switch loop method and conditional that is not needed

* Switch to source_server instead of source_client

---------

Co-authored-by: Andrei Litvin <[email protected]>
  • Loading branch information
2 people authored and pull[bot] committed Jul 29, 2023
1 parent 3879bcf commit 1132326
Show file tree
Hide file tree
Showing 52 changed files with 3,608 additions and 1,017 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -273,9 +273,23 @@ client cluster OnOff = 6 {
readonly attribute bitmap32 featureMap = 65532;
readonly attribute int16u clusterRevision = 65533;

request struct OffWithEffectRequest {
OnOffEffectIdentifier effectIdentifier = 0;
int8u effectVariant = 1;
}

request struct OnWithTimedOffRequest {
OnOffControl onOffControl = 0;
int16u onTime = 1;
int16u offWaitTime = 2;
}

command Off(): DefaultSuccess = 0;
command On(): DefaultSuccess = 1;
command Toggle(): DefaultSuccess = 2;
command OffWithEffect(OffWithEffectRequest): DefaultSuccess = 64;
command OnWithRecallGlobalScene(): DefaultSuccess = 65;
command OnWithTimedOff(OnWithTimedOffRequest): DefaultSuccess = 66;
}

server cluster OnOff = 6 {
Expand Down Expand Up @@ -746,21 +760,32 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForProvider = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
response struct QueryImageResponse = 1 {
OTAQueryStatus status = 0;
optional INT32U delayedActionTime = 1;
optional CHAR_STRING<256> imageURI = 2;
optional INT32U softwareVersion = 3;
optional CHAR_STRING<64> softwareVersionString = 4;
optional OCTET_STRING<32> updateToken = 5;
optional BOOLEAN userConsentNeeded = 6;
optional OCTET_STRING<512> metadataForRequestor = 7;
}

request struct NotifyUpdateAppliedRequest {
request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
INT32U newVersion = 1;
}

response struct ApplyUpdateResponse = 3 {
OTAApplyUpdateAction action = 0;
INT32U delayedActionTime = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

command QueryImage(QueryImageRequest): QueryImageResponse = 0;
command ApplyUpdateRequest(ApplyUpdateRequestRequest): ApplyUpdateResponse = 2;
command NotifyUpdateApplied(NotifyUpdateAppliedRequest): DefaultSuccess = 4;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -631,21 +631,32 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForProvider = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
response struct QueryImageResponse = 1 {
OTAQueryStatus status = 0;
optional INT32U delayedActionTime = 1;
optional CHAR_STRING<256> imageURI = 2;
optional INT32U softwareVersion = 3;
optional CHAR_STRING<64> softwareVersionString = 4;
optional OCTET_STRING<32> updateToken = 5;
optional BOOLEAN userConsentNeeded = 6;
optional OCTET_STRING<512> metadataForRequestor = 7;
}

request struct NotifyUpdateAppliedRequest {
request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
INT32U newVersion = 1;
}

response struct ApplyUpdateResponse = 3 {
OTAApplyUpdateAction action = 0;
INT32U delayedActionTime = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

command QueryImage(QueryImageRequest): QueryImageResponse = 0;
command ApplyUpdateRequest(ApplyUpdateRequestRequest): ApplyUpdateResponse = 2;
command NotifyUpdateApplied(NotifyUpdateAppliedRequest): DefaultSuccess = 4;
Expand Down
20 changes: 10 additions & 10 deletions examples/chef/devices/noip_rootnode_dimmablelight_bCwGYSDpoe.matter
Original file line number Diff line number Diff line change
Expand Up @@ -435,16 +435,6 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForProvider = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

response struct QueryImageResponse = 1 {
OTAQueryStatus status = 0;
optional INT32U delayedActionTime = 1;
Expand All @@ -456,11 +446,21 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForRequestor = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

response struct ApplyUpdateResponse = 3 {
OTAApplyUpdateAction action = 0;
INT32U delayedActionTime = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

command QueryImage(QueryImageRequest): QueryImageResponse = 0;
command ApplyUpdateRequest(ApplyUpdateRequestRequest): ApplyUpdateResponse = 2;
command NotifyUpdateApplied(NotifyUpdateAppliedRequest): DefaultSuccess = 4;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -444,16 +444,6 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForProvider = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

response struct QueryImageResponse = 1 {
OTAQueryStatus status = 0;
optional INT32U delayedActionTime = 1;
Expand All @@ -465,11 +455,21 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForRequestor = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

response struct ApplyUpdateResponse = 3 {
OTAApplyUpdateAction action = 0;
INT32U delayedActionTime = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

command QueryImage(QueryImageRequest): QueryImageResponse = 0;
command ApplyUpdateRequest(ApplyUpdateRequestRequest): ApplyUpdateResponse = 2;
command NotifyUpdateApplied(NotifyUpdateAppliedRequest): DefaultSuccess = 4;
Expand Down
20 changes: 10 additions & 10 deletions examples/chef/devices/rootnode_contactsensor_lFAGG1bfRO.matter
Original file line number Diff line number Diff line change
Expand Up @@ -288,16 +288,6 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForProvider = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

response struct QueryImageResponse = 1 {
OTAQueryStatus status = 0;
optional INT32U delayedActionTime = 1;
Expand All @@ -309,11 +299,21 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForRequestor = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

response struct ApplyUpdateResponse = 3 {
OTAApplyUpdateAction action = 0;
INT32U delayedActionTime = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

command QueryImage(QueryImageRequest): QueryImageResponse = 0;
command ApplyUpdateRequest(ApplyUpdateRequestRequest): ApplyUpdateResponse = 2;
command NotifyUpdateApplied(NotifyUpdateAppliedRequest): DefaultSuccess = 4;
Expand Down
20 changes: 10 additions & 10 deletions examples/chef/devices/rootnode_dimmablelight_bCwGYSDpoe.matter
Original file line number Diff line number Diff line change
Expand Up @@ -435,16 +435,6 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForProvider = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

response struct QueryImageResponse = 1 {
OTAQueryStatus status = 0;
optional INT32U delayedActionTime = 1;
Expand All @@ -456,11 +446,21 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForRequestor = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

response struct ApplyUpdateResponse = 3 {
OTAApplyUpdateAction action = 0;
INT32U delayedActionTime = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

command QueryImage(QueryImageRequest): QueryImageResponse = 0;
command ApplyUpdateRequest(ApplyUpdateRequestRequest): ApplyUpdateResponse = 2;
command NotifyUpdateApplied(NotifyUpdateAppliedRequest): DefaultSuccess = 4;
Expand Down
20 changes: 10 additions & 10 deletions examples/chef/devices/rootnode_doorlock_aNKYAreMXE.matter
Original file line number Diff line number Diff line change
Expand Up @@ -288,16 +288,6 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForProvider = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

response struct QueryImageResponse = 1 {
OTAQueryStatus status = 0;
optional INT32U delayedActionTime = 1;
Expand All @@ -309,11 +299,21 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForRequestor = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

response struct ApplyUpdateResponse = 3 {
OTAApplyUpdateAction action = 0;
INT32U delayedActionTime = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

command QueryImage(QueryImageRequest): QueryImageResponse = 0;
command ApplyUpdateRequest(ApplyUpdateRequestRequest): ApplyUpdateResponse = 2;
command NotifyUpdateApplied(NotifyUpdateAppliedRequest): DefaultSuccess = 4;
Expand Down
20 changes: 10 additions & 10 deletions examples/chef/devices/rootnode_extendedcolorlight_8lcaaYJVAa.matter
Original file line number Diff line number Diff line change
Expand Up @@ -435,16 +435,6 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForProvider = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

response struct QueryImageResponse = 1 {
OTAQueryStatus status = 0;
optional INT32U delayedActionTime = 1;
Expand All @@ -456,11 +446,21 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForRequestor = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

response struct ApplyUpdateResponse = 3 {
OTAApplyUpdateAction action = 0;
INT32U delayedActionTime = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

command QueryImage(QueryImageRequest): QueryImageResponse = 0;
command ApplyUpdateRequest(ApplyUpdateRequestRequest): ApplyUpdateResponse = 2;
command NotifyUpdateApplied(NotifyUpdateAppliedRequest): DefaultSuccess = 4;
Expand Down
20 changes: 10 additions & 10 deletions examples/chef/devices/rootnode_fan_7N2TobIlOX.matter
Original file line number Diff line number Diff line change
Expand Up @@ -285,16 +285,6 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForProvider = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

response struct QueryImageResponse = 1 {
OTAQueryStatus status = 0;
optional INT32U delayedActionTime = 1;
Expand All @@ -306,11 +296,21 @@ client cluster OtaSoftwareUpdateProvider = 41 {
optional OCTET_STRING<512> metadataForRequestor = 7;
}

request struct ApplyUpdateRequestRequest {
OCTET_STRING<32> updateToken = 0;
INT32U newVersion = 1;
}

response struct ApplyUpdateResponse = 3 {
OTAApplyUpdateAction action = 0;
INT32U delayedActionTime = 1;
}

request struct NotifyUpdateAppliedRequest {
OCTET_STRING<32> updateToken = 0;
INT32U softwareVersion = 1;
}

command QueryImage(QueryImageRequest): QueryImageResponse = 0;
command ApplyUpdateRequest(ApplyUpdateRequestRequest): ApplyUpdateResponse = 2;
command NotifyUpdateApplied(NotifyUpdateAppliedRequest): DefaultSuccess = 4;
Expand Down
Loading

0 comments on commit 1132326

Please sign in to comment.