Skip to content

Commit

Permalink
Merge branch 'master' into run_rvc_tests_in_ci
Browse files Browse the repository at this point in the history
  • Loading branch information
hicklin committed Feb 14, 2024
2 parents b73f128 + db09a64 commit 298026c
Show file tree
Hide file tree
Showing 221 changed files with 3,982 additions and 2,134 deletions.
1 change: 0 additions & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,6 @@ jobs:
--known-failure app/util/ember-compatibility-functions.cpp \
--known-failure app/util/endpoint-config-api.h \
--known-failure app/util/endpoint-config-defines.h \
--known-failure app/util/error-mapping.h \
--known-failure app/util/generic-callbacks.h \
--known-failure app/util/generic-callback-stubs.cpp \
--known-failure app/util/im-client-callbacks.h \
Expand Down
9 changes: 8 additions & 1 deletion .github/workflows/tests.yaml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/QUICK_START.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ combination listed below.

| <div style="width:200px">Border Router</div> | <div style="width:200px">Node</div> | Description |
| -------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [**ot-br**](https://openthread.io/guides/border-router/build)<br>Thread Border Router <li>RasPi <li>BeagleBone | **lighting-app** <li>[Nordic nRF5x](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/nrfconnect/README.md) <li> [NXP K32W](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/nxp/k32w/k32w0/README.md) <li> [Qorvo QPG6100](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/qpg) <li> [Silicon Labs EFR32](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/efr32/README.md) | The Lighting example is supported by many of the available Thread platforms. See the chip-tool controller instructions for how to actuate the light on/off cluster. |
| [**ot-br**](https://openthread.io/guides/border-router/build)<br>Thread Border Router <li>RasPi <li>BeagleBone | **lighting-app** <li>[Nordic nRF5x](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/nrfconnect/README.md) <li> [NXP K32W](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/nxp/k32w/k32w0/README.md) <li> [Qorvo QPG6100](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/qpg) <li> [Silicon Labs EFR32](https://github.com/project-chip/connectedhomeip/tree/master/examples/lighting-app/silabs/README.md) | The Lighting example is supported by many of the available Thread platforms. See the chip-tool controller instructions for how to actuate the light on/off cluster. |
| [**ot-br**](https://openthread.io/guides/border-router/build)<br>Thread Border Router <li>RasPi <li>BeagleBone | **lock-app** <li>[Nordic nRF5x](https://github.com/project-chip/connectedhomeip/tree/master/examples/lock-app/nrfconnect/README.md) <li> [NXP K32W](https://github.com/project-chip/connectedhomeip/tree/master/examples/lock-app/nxp/k32w/k32w0/README.md) <li> [Qorvo QPG6100](https://github.com/project-chip/connectedhomeip/tree/master/examples/lock-app/qpg) <li> [Silicon Labs EFR32](https://github.com/project-chip/connectedhomeip/tree/master/examples/lock-app/efr32/README.md) <li> [TI CC13x2x7](https://github.com/project-chip/connectedhomeip/tree/master/examples/lock-app/cc13x2x7_26x2x7/README.md) | The Lock example is supported by many of the available Thread and Wi-Fi platforms. |

## Controllers
Expand Down
2 changes: 1 addition & 1 deletion docs/guides/silabs_efr32_software_update.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ all of the EFR32 example applications.
## Running the OTA Download scenario

- For Matter with OpenThread: Bring up the OpenThread Border Router as
discussed in examples/lighting-app/efr32/README.md and get its operational
discussed in examples/lighting-app/silabs/README.md and get its operational
dataset.

- On a Linux or Darwin platform build the chip-tool and the ota-provider-app
Expand Down
22 changes: 14 additions & 8 deletions docs/guides/ti/matter_cc2674_migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ project accordingly. Example projects can be found in the following location:
The following must be installed on your system before proceeding:

- [SysConfig](https://www.ti.com/tool/SYSCONFIG) v1.16.2 or later
- [SIMPLELINK-LOWPOWER-F2-SDK](https://www.ti.com/tool/SIMPLELINK-LOWPOWER-SDK)
v7.10.01.24

## Matter source code changes

Expand All @@ -22,12 +20,20 @@ CC2674P10 device

- `examples/[application]/cc13x4_26x4/args.gni`, modify/add the following
defines for the CC2674
- `ti_simplelink_board = CC2674`
- `ti_simplelink_device = CC2674P10RGZ`
- `third_party/ti_simplelink_sdk/repo_cc13xx_cc26xx`, replace this folder
contents with the 7.10.01.24 version from
[TI's downloads page](https://www.ti.com/tool/download/SIMPLELINK-LOWPOWER-F2-SDK/7.10.01.24)
which is required to add support SDK for the CC2674P10 device.
- `ti_simplelink_board = "CC2674"`
- `ti_simplelink_device = "CC2674P10RGZ"`
- `third_party/ti_simplelink_sdk/repo_cc13xx_cc26xx/source/ti/common/flash/no_rtos/extFlash/bsp.h`,
modify the SPI GPIO pins to the value below:

```
#define BSP_IOID_FLASH_CS IOID_20
#define BSP_SPI_MOSI IOID_9
#define BSP_SPI_MISO IOID_8
#define BSP_SPI_CLK_FLASH IOID_10
```

The GPIO pin values for SPI will need to be adjusted based on your design.

## Configuring `chip.syscfg` in the SysConfig GUI

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
#pragma once

#include <app-common/zap-generated/attributes/Accessors.h>
#include <protocols/interaction_model/StatusCode.h>

namespace chip {
namespace app {
Expand All @@ -31,19 +32,20 @@ class RelativeHumiditySensorManager

void Init()
{
EmberAfStatus status = RelativeHumidityMeasurement::Attributes::MinMeasuredValue::Set(mEndpointId, 0);
VerifyOrReturn(EMBER_ZCL_STATUS_SUCCESS == status,
Protocols::InteractionModel::Status status = RelativeHumidityMeasurement::Attributes::MinMeasuredValue::Set(mEndpointId, 0);
VerifyOrReturn(Protocols::InteractionModel::Status::Success == status,
ChipLogError(NotSpecified, "Failed to set RelativeHumidityMeasurement MinMeasuredValue attribute"));

status = RelativeHumidityMeasurement::Attributes::MaxMeasuredValue::Set(mEndpointId, 10000);
VerifyOrReturn(EMBER_ZCL_STATUS_SUCCESS == status,
VerifyOrReturn(Protocols::InteractionModel::Status::Success == status,
ChipLogError(NotSpecified, "Failed to set RelativeHumidityMeasurement MaxMeasuredValue attribute"));
};

void OnHumidityChangeHandler(uint16_t newValue)
{
EmberAfStatus status = RelativeHumidityMeasurement::Attributes::MeasuredValue::Set(mEndpointId, newValue);
VerifyOrReturn(EMBER_ZCL_STATUS_SUCCESS == status,
Protocols::InteractionModel::Status status =
RelativeHumidityMeasurement::Attributes::MeasuredValue::Set(mEndpointId, newValue);
VerifyOrReturn(Protocols::InteractionModel::Status::Success == status,
ChipLogError(NotSpecified, "Failed to set RelativeHumidityMeasurement MeasuredValue attribute"));
ChipLogDetail(NotSpecified, "The new RelativeHumidityMeasurement value: %d", newValue);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
#pragma once

#include <app-common/zap-generated/attributes/Accessors.h>
#include <protocols/interaction_model/StatusCode.h>

namespace chip {
namespace app {
Expand All @@ -31,19 +32,19 @@ class TemperatureSensorManager

void Init()
{
EmberAfStatus status = TemperatureMeasurement::Attributes::MinMeasuredValue::Set(mEndpointId, -500);
VerifyOrReturn(EMBER_ZCL_STATUS_SUCCESS == status,
Protocols::InteractionModel::Status status = TemperatureMeasurement::Attributes::MinMeasuredValue::Set(mEndpointId, -500);
VerifyOrReturn(Protocols::InteractionModel::Status::Success == status,
ChipLogError(NotSpecified, "Failed to set TemperatureMeasurement MinMeasuredValue attribute"));

status = TemperatureMeasurement::Attributes::MaxMeasuredValue::Set(mEndpointId, 6000);
VerifyOrReturn(EMBER_ZCL_STATUS_SUCCESS == status,
VerifyOrReturn(Protocols::InteractionModel::Status::Success == status,
ChipLogError(NotSpecified, "Failed to set TemperatureMeasurement MaxMeasuredValue attribute"));
}

void OnTemperatureChangeHandler(int16_t newValue)
{
EmberAfStatus status = TemperatureMeasurement::Attributes::MeasuredValue::Set(mEndpointId, newValue);
VerifyOrReturn(EMBER_ZCL_STATUS_SUCCESS == status,
Protocols::InteractionModel::Status status = TemperatureMeasurement::Attributes::MeasuredValue::Set(mEndpointId, newValue);
VerifyOrReturn(Protocols::InteractionModel::Status::Success == status,
ChipLogError(NotSpecified, "Failed to set TemperatureMeasurement MeasuredValue attribute"));
ChipLogDetail(NotSpecified, "The new TemperatureMeasurement value: %d", newValue);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
*/

#include <air-purifier-manager.h>
#include <app/util/error-mapping.h>

using namespace chip;
using namespace chip::app;
Expand Down Expand Up @@ -147,7 +146,7 @@ Status AirPurifierManager::HandleStep(FanControl::StepDirectionEnum aDirection,
}
}

return ToInteractionModelStatus(FanControl::Attributes::SpeedSetting::Set(mEndpointId, newSpeedSetting));
return FanControl::Attributes::SpeedSetting::Set(mEndpointId, newSpeedSetting);
}

void AirPurifierManager::HandleFanControlAttributeChange(AttributeId attributeId, uint8_t type, uint16_t size, uint8_t * value)
Expand Down Expand Up @@ -197,12 +196,13 @@ void AirPurifierManager::PercentSettingWriteCallback(uint8_t aNewPercentSetting)
if (aNewPercentSetting != percentCurrent)
{
ChipLogDetail(NotSpecified, "AirPurifierManager::PercentSettingWriteCallback: %d", aNewPercentSetting);
percentCurrent = aNewPercentSetting;
EmberAfStatus status = FanControl::Attributes::PercentCurrent::Set(mEndpointId, percentCurrent);
if (status != EMBER_ZCL_STATUS_SUCCESS)
percentCurrent = aNewPercentSetting;
Status status = FanControl::Attributes::PercentCurrent::Set(mEndpointId, percentCurrent);
if (status != Status::Success)
{
ChipLogError(NotSpecified,
"AirPurifierManager::PercentSettingWriteCallback: failed to set PercentCurrent attribute: %d", status);
"AirPurifierManager::PercentSettingWriteCallback: failed to set PercentCurrent attribute: %d",
to_underlying(status));
}
}
}
Expand All @@ -212,12 +212,12 @@ void AirPurifierManager::SpeedSettingWriteCallback(uint8_t aNewSpeedSetting)
if (aNewSpeedSetting != speedCurrent)
{
ChipLogDetail(NotSpecified, "AirPurifierManager::SpeedSettingWriteCallback: %d", aNewSpeedSetting);
speedCurrent = aNewSpeedSetting;
EmberAfStatus status = FanControl::Attributes::SpeedCurrent::Set(mEndpointId, speedCurrent);
if (status != EMBER_ZCL_STATUS_SUCCESS)
speedCurrent = aNewSpeedSetting;
Status status = FanControl::Attributes::SpeedCurrent::Set(mEndpointId, speedCurrent);
if (status != Status::Success)
{
ChipLogError(NotSpecified, "AirPurifierManager::SpeedSettingWriteCallback: failed to set SpeedCurrent attribute: %d",
status);
to_underlying(status));
}

// Determine if the speed change should also change the fan mode
Expand Down Expand Up @@ -300,22 +300,24 @@ void AirPurifierManager::SetSpeedSetting(DataModel::Nullable<uint8_t> aNewSpeedS

if (aNewSpeedSetting.Value() != speedCurrent)
{
EmberAfStatus status = FanControl::Attributes::SpeedSetting::Set(mEndpointId, aNewSpeedSetting);
if (status != EMBER_ZCL_STATUS_SUCCESS)
Status status = FanControl::Attributes::SpeedSetting::Set(mEndpointId, aNewSpeedSetting);
if (status != Status::Success)
{
ChipLogError(NotSpecified, "AirPurifierManager::SetSpeedSetting: failed to set SpeedSetting attribute: %d", status);
ChipLogError(NotSpecified, "AirPurifierManager::SetSpeedSetting: failed to set SpeedSetting attribute: %d",
to_underlying(status));
}
}
}

DataModel::Nullable<uint8_t> AirPurifierManager::GetSpeedSetting()
{
DataModel::Nullable<uint8_t> speedSetting;
EmberAfStatus status = FanControl::Attributes::SpeedSetting::Get(mEndpointId, speedSetting);
Status status = FanControl::Attributes::SpeedSetting::Get(mEndpointId, speedSetting);

if (status != EMBER_ZCL_STATUS_SUCCESS)
if (status != Status::Success)
{
ChipLogError(NotSpecified, "AirPurifierManager::GetSpeedSetting: failed to get SpeedSetting attribute: %d", status);
ChipLogError(NotSpecified, "AirPurifierManager::GetSpeedSetting: failed to get SpeedSetting attribute: %d",
to_underlying(status));
}

return speedSetting;
Expand All @@ -324,11 +326,12 @@ DataModel::Nullable<uint8_t> AirPurifierManager::GetSpeedSetting()
DataModel::Nullable<Percent> AirPurifierManager::GetPercentSetting()
{
DataModel::Nullable<Percent> percentSetting;
EmberAfStatus status = FanControl::Attributes::PercentSetting::Get(mEndpointId, percentSetting);
Status status = FanControl::Attributes::PercentSetting::Get(mEndpointId, percentSetting);

if (status != EMBER_ZCL_STATUS_SUCCESS)
if (status != Status::Success)
{
ChipLogError(NotSpecified, "AirPurifierManager::GetPercentSetting: failed to get PercentSetting attribute: %d", status);
ChipLogError(NotSpecified, "AirPurifierManager::GetPercentSetting: failed to get PercentSetting attribute: %d",
to_underlying(status));
}

return percentSetting;
Expand Down
Loading

0 comments on commit 298026c

Please sign in to comment.