Skip to content

Commit

Permalink
Pull request project-chip#1490: Add missing boards and sample app in CI
Browse files Browse the repository at this point in the history
Merge in WMN_TOOLS/matter from ci_add_sample_app_and_boards to silabs

Squashed commit of the following:

commit 9ca684e6801158140b6e3f9a1b532d8d86dae354
Author: Junior Martinez <[email protected]>
Date:   Fri Jan 12 15:43:16 2024 -0500

    Fix dishwasher operation-state-degate-impl due to change to the CSA delegate

commit a354504499ed4e1b9b4f49d82540ddee4f5c98e0
Author: jepenven-silabs <[email protected]>
Date:   Fri Jan 12 15:05:53 2024 -0500

    fis path diswasher

commit 9b4555642323e405e0fa65465b2cf8d38c507b7f
Author: jepenven-silabs <[email protected]>
Date:   Fri Jan 12 12:01:03 2024 -0500

    Add missing boards and sample app in CI
  • Loading branch information
jepenven-silabs authored and jmartinez-silabs committed Mar 27, 2024
1 parent 682df72 commit fa2ecc6
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 16 deletions.
18 changes: 16 additions & 2 deletions silabs_ci_scripts/pipeline/apps.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,21 @@
{
"name": "onoff-plug",
"path": "./silabs_examples/onoff-plug-app/",
"boards": ["BRD4161A", "BRD4166A", "BRD4186C", "BRD4187C", "BRD4338A"],
"boards": ["BRD4161A", "BRD4166A", "BRD4186C", "BRD4187C", "BRD4338A", "BRD4316A"],
"rcp" : ["", "rs9116", "wf200"],
"variants" : ["all"],
"automation" : "",
"appBuildArgs" : [
{
"name" : "",
"option": ""
}
]
},
{
"name": "dishwasher",
"path": "./silabs_examples/dishwasher-app/silabs/",
"boards": ["BRD4161A", "BRD4166A", "BRD4186C", "BRD4187C", "BRD4338A", "BRD4316A"],
"rcp" : ["", "rs9116", "wf200"],
"variants" : ["all"],
"automation" : "",
Expand Down Expand Up @@ -101,7 +115,7 @@
{
"name": "sensors",
"path": "./silabs_examples/silabs-sensors/",
"boards": ["BRD4161A", "BRD4166A", "BRD4186C", "BRD4187C", "BRD4338A"],
"boards": ["BRD4161A", "BRD4166A", "BRD4186C", "BRD4187C", "BRD4338A", "BRD4316A"],
"rcp" : [""],
"variants" : ["all"],
"automation" : "",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,16 @@ class OperationalStateDelegate : public Delegate

/**
* Get the list of supported operational phases.
* Fills in the provided GenericOperationalPhase with the phase at index `index` if there is one,
* Fills in the provided MutableCharSpan with the phase at index `index` if there is one,
* or returns CHIP_ERROR_NOT_FOUND if the index is out of range for the list of phases.
*
* If CHIP_ERROR_NOT_FOUND is returned for index 0, that indicates that the PhaseList attribute is null
* (there are no phases defined at all).
*
* @param index The index of the phase, with 0 representing the first phase.
* @param operationalPhase The GenericOperationalPhase is filled.
* @param operationalPhase The MutableCharSpan is filled.
*/
CHIP_ERROR GetOperationalPhaseAtIndex(size_t index, GenericOperationalPhase & operationalPhase) override;
CHIP_ERROR GetOperationalPhaseAtIndex(size_t index, MutableCharSpan & operationalPhase) override;

// command callback
/**
Expand Down Expand Up @@ -103,13 +107,7 @@ class OperationalStateDelegate : public Delegate
};

app::DataModel::List<const GenericOperationalState> mOperationalStateList = Span<const GenericOperationalState>(rvcOpStateList);

const GenericOperationalPhase opPhaseList[1] = {
// Phase List is null
GenericOperationalPhase(DataModel::Nullable<CharSpan>()),
};

Span<const GenericOperationalPhase> mOperationalPhaseList = Span<const GenericOperationalPhase>(opPhaseList);
const Span<const CharSpan> mOperationalPhaseList;
};

OperationalState::Instance* GetInstance();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,13 @@ CHIP_ERROR OperationalStateDelegate::GetOperationalStateAtIndex(size_t index, Ge
return CHIP_NO_ERROR;
}

CHIP_ERROR OperationalStateDelegate::GetOperationalPhaseAtIndex(size_t index, GenericOperationalPhase & operationalPhase)
CHIP_ERROR OperationalStateDelegate::GetOperationalPhaseAtIndex(size_t index, MutableCharSpan & operationalPhase)
{
if (index > mOperationalPhaseList.size() - 1)
if (index >= mOperationalPhaseList.size())
{
return CHIP_ERROR_NOT_FOUND;
}
operationalPhase = mOperationalPhaseList[index];
return CHIP_NO_ERROR;
return CopyCharSpanToMutableCharSpan(mOperationalPhaseList[index], operationalPhase);
}

void OperationalStateDelegate::HandlePauseStateCallback(GenericOperationalError & err)
Expand Down

0 comments on commit fa2ecc6

Please sign in to comment.