Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
144 changes: 72 additions & 72 deletions sld297-matter-aws-feature/build-matter-aws.md
Original file line number Diff line number Diff line change
@@ -1,72 +1,72 @@
# Build Procedure For Matter + AWS

The following components are common for all apps and should be modified in the corresponding application-specific `.slcp` file.

## How to Add the Matter + AWS Component

To add the Matter + AWS component, modify the corresponding application-specific `.slcp` file.

```shell
- id: matter_aws
from: matter
```
To enable the component in Simplicity Studio, add the following components.

- Go to **Software** components, search for `Matter_Wifi`. Click on **Settings** symbol beside Matter Wi-fi component in the left panel and enable IPV4 configuration.
![IPV4 Component](images/matter_aws_ipv4_enable_1.png)
![IPV4 Settings Enable](images/matter_aws_ipv4_enable_2.png)

- In **Software Components**, search for `aws` and install the Matter AWS component.

- Next, select the dependencies for the Matter AWS component.
![Default Entropy Source for Matter + AWS](images/matter_aws_dependency_1.png)
![Public-Key Abstaction Layer for Matter + AWS](images/matter_aws_dependency_2.png)

## How to Add the Matter + AWS Server, Client, Cluster Details.

- Update the definitions for the server ID, client ID and cluster in `MatterAwsConfig.h`:
    - Update the AWS server name at `#define MATTER_AWS_SERVER_HOST ""`.
    - Update the client ID at `#define MATTER_AWS_CLIENT_ID ""`.
    - Update the cluster information at `#define ZCL_USING_THERMOSTAT_CLUSTER_SERVER`.


## Building Matter + AWS Application

- After you finish modifying the **.slcp** project file as described above, refresh the `matter-extension` in Simplicity Studio.

- On the **Launcher** tab, select **Preferences**.

![Select Preferences](images/select-preferences.png)

- Expand the **Simplicity Studio** section, and click the **SDKs** tab.

![Select SDK](images/select-studio-sdk-option.png)

- Expand **Simplicity SDK**, and click **Refresh** in the side menu.

![Select Refresh](images/select-refresh-option.png)

- Build the Matter + AWS application using Simplicity Studio as described in
- [Build SOC Application Using Studio](/matter/{build-docspace-version}/matter-wifi-run-demo/build-soc-application-using-studio).

## Compile using new/different certificates

- Two devices should not use the same client ID. Use a different client ID for
your second connection.
- While using AWS, update the following information:
- Add your AWS certificates in file
`examples/platform/silabs/matter_aws/matter_aws_interface/include/MatterAwsNvmCert.h`
- Provide the AWS Root CA key
(https://www.amazontrust.com/repository/AmazonRootCA3.pem)
- Provide `device_certificate` and `device_key` with your device certificate and
device key. For more details, refer to
[OpenSSL Device Certificate Creation] (./openssl-certificate-creation.md)
- Add your AWS server and client ID information to the
`examples/platform/silabs/matter_aws/matter_aws_interface/include/MatterAwsConfig.h` file.
- Provide `MATTER_AWS_SERVER_HOST` with your AWS Server name.
- Provide `MATTER_AWS_CLIENT_ID` with your device/thing ID.
- Provide `ZCL_USING_THERMOSTAT_CLUSTER_SERVER` with the cluster details.
- The preferred certificate type to use in the application is ECDSA.
- AWS RootCA used in this PoC is
https://www.amazontrust.com/repository/AmazonRootCA3.pem

# Build Procedure For Matter + AWS
The following components are common for all apps and should be modified in the corresponding application-specific `.slcp` file using the Studio Project Configurator tool.
## How to Add the Matter + AWS Component
To enable the component in Simplicity Studio, add the following components.
- Go to **Software** components, search for `Matter_Wifi`. Click on **Settings** symbol beside Matter Wi-fi component in the left panel and enable IPV4 configuration.
![IPV4 Component](images/matter_aws_ipv4_enable_1.png)
![IPV4 Settings Enable](images/matter_aws_ipv4_enable_2.png)
- In **Software Components**, search for `aws` and install the Matter AWS component.
- Next, select the dependencies for the Matter AWS component.
![Default Entropy Source for Matter + AWS](images/matter_aws_dependency_1.png)
![Public-Key Abstaction Layer for Matter + AWS](images/matter_aws_dependency_2.png)
## How to Add the Matter + AWS Server, Client, Cluster Details.
- Go to the `matter_<version>/third_party/matter_sdk/examples/platform/silabs/matter_aws/matter_aws_interface/include/` folder from Project Explorer.
- Update the definitions for the server ID, client ID and cluster in `MatterAwsConfig.h`:
- Update the AWS server name at `#define MATTER_AWS_SERVER_HOST ""`.
- Update the client ID at `#define MATTER_AWS_CLIENT_ID ""`.
- Update the cluster information based on your app, with reference to the below table:
| Application Type | Cluster Definition |
|------------------|--------------------|
| Matter Thermostat | `#define ZCL_USING_THERMOSTAT_CLUSTER_SERVER` |
| Matter Light | `#define ZCL_USING_ON_OFF_CLUSTER_SERVER` |
| Matter Lock | `#define ZCL_USING_DOOR_LOCK_CLUSTER_SERVER` |
| Matter Window Covering | `#define ZCL_USING_WINDOW_COVERING_CLUSTER_SERVER` |
## Building Matter + AWS Application
- After adding the Matter + AWS component as described above, refresh the `matter-extension` in Simplicity Studio.
- On the **Launcher** tab, select **Preferences**.
![Select Preferences](images/select-preferences.png)
- Expand the **Simplicity Studio** section, and click the **SDKs** tab.
![Select SDK](images/select-studio-sdk-option.png)
- Expand **Simplicity SDK**, and click **Refresh** in the side menu.
![Select Refresh](images/select-refresh-option.png)
- Build the Matter + AWS application using Simplicity Studio as described in
- [Build SOC Application Using Studio](/matter/{build-docspace-version}/matter-wifi-run-demo/build-soc-application-using-studio).
## Compile using new/different certificates
- Two devices should not use the same client ID. Use a different client ID for
your second connection.
- While using AWS, update the following information:
- Add your AWS certificates in file
`examples/platform/silabs/matter_aws/matter_aws_interface/include/MatterAwsNvmCert.h`
- Provide the AWS Root CA key
(https://www.amazontrust.com/repository/AmazonRootCA3.pem)
- Provide `device_certificate` and `device_key` with your device certificate and
device key. For more details, refer to
[OpenSSL Device Certificate Creation] (./openssl-certificate-creation.md)
- Add your AWS server and client ID information to the
`examples/platform/silabs/matter_aws/matter_aws_interface/include/MatterAwsConfig.h` file.
- Provide `MATTER_AWS_SERVER_HOST` with your AWS Server name.
- Provide `MATTER_AWS_CLIENT_ID` with your device/thing ID.
- Provide `ZCL_USING_THERMOSTAT_CLUSTER_SERVER` with the cluster details.
- The preferred certificate type to use in the application is ECDSA.
- AWS RootCA used in this PoC is
https://www.amazontrust.com/repository/AmazonRootCA3.pem
250 changes: 126 additions & 124 deletions sld297-matter-aws-feature/index.md
Original file line number Diff line number Diff line change
@@ -1,124 +1,126 @@
# Matter + AWS Component

- Matter + AWS is a Silicon Labs–specific feature that enables Matter devices to connect directly to
proprietary cloud solutions, such as AWS Cloud. As such, a Matter Wi-Fi device
must support connecting locally on the Matter Fabric via IPv6 and
connecting to the Internet via IPv4.
- Matter devices can be controlled by chip-tool or a controller. The
status of the modified attributes will be published to the cloud.
- Remote users can install a cloud-specific application to receive
notifications about the attribute status.

## Matter + AWS Feature Diagram

The following diagram shows end-to-end flow for Direct Internet Connectivity.

![Silicon Labs - Matter + AWS design](./images/matter-aws-flow.png)

## Prerequisites

### Hardware Requirements

For a list of hardware requirements for the Matter + AWS feature, see the
official
[Silicon Labs Matter hardware requirements](https://siliconlabs.github.io/matter/latest/general/HARDWARE_REQUIREMENTS.html)
documentation.

### Software Requirements

For a list of software requirements for the Matter + AWS feature, see the
official
[Silicon Labs Matter Software requirements](https://siliconlabs.github.io/matter/latest/general/SOFTWARE_REQUIREMENTS.html)
documentation.

## End-to-End Set-up bring up

### Message Queuing Telemetry Transport (MQTT)

MQTT is an OASIS standard messaging protocol for the Internet of Things
(IoT). It is designed as an extremely lightweight publish/subscribe
messaging transport that is ideal for connecting remote devices with a small
code footprint and minimal network bandwidth.
For more details, visit https://mqtt.org/.

### Configuring the MQTT server

To set up and configure AWS for Matter + AWS support, see the following documentation:

- [AWS installation](./aws-configuration-registration.md)

### Remote User Setup (MQTT Explorer) (optional)

Remote users are used to check the state of Matter devices. In this context, MQTT Explorer acts as a remote user. For more information, see [MQTT Explorer Setup and Configuration](./mqtt-explorer-setup.md).

### Building Matter + AWS Application using Simplicity Studio

Follow the instructions in [Build MATTER + AWS](./build-matter-aws.md) to enable the MATTER + AWS feature in your application code.


## End-to-End Test of Matter + AWS Application

User Setup (MQTT Explorer):

- Sharing status of device to cloud
- The following diagram shows the end-to-end flow for sharing status from a Matter device to the cloud.

![Silicon Labs - Matter + AWS design](images/dic-status-sharing.png)

**Note**: For reference, the diagram shows Lighting App commands. Other application commands also can be passed.

- For the end-to-end commands to be executed from chip-tool, refer to [Running the Matter Demo Over Wi-Fi](/matter/{build-docspace-version}/matter-wifi-run-demo).
- The following application-specific attributes or states are shared to the cloud:
- For Lighting App, On/Off Attributes
- For Lock App, lock/unlock Attributes
- For Windows App, lift/tilt Attributes
- For Thermostat App, SystemMode/CurrentTemp/LocalTemperature/OccupiedCoolingSetpoint/OccupiedHeatingSetpoint Attributes
- For On/off Plug App, On/Off Attributes
- The MQTT Explorer UI updates the application status as shown in following image.

![Matter + AWS status update](images/mqtt-explorer-4.png)

- Control of the device through cloud interface
- The following diagram shows the end-to-end flow for control of the Matter device through a cloud interface.

![Silicon Labs - Matter + AWS design](images/dic-control-part.png)

**Note**: For reference, the diagram shows Lighting App commands. Other application commands also can be passed.

- Ensure that the Matter device is running and successfully commissioned. For detailed steps, refer to [Running the Matter Demo Over Wi-Fi](/matter/{build-docspace-version}/matter-wifi-run-demo).
- To control the device, set the topic name and the commands to be executed in the MQTT Explorer for the following applications.

```shell
- Lighting App
- Topic: command
- Commands:
- toggle
- on
- off
- Onoff-plug App
- Topic: command
- Commands:
- toggle
- on
- off
- Lock App
- Topic: command
- Commands:
- lock
- unlock
- Thermostat App
- Topic: command
- Commands:
- SetMode/value(value need to provide 1,2,3,4 ex:SetMode/1)
- Heating/value(value need to provide 2500,2600 ex:HeatingSetPoint/2500)
- Cooling/value(value need to provide 2500,2600 ex:CoolingSetPoint/2500)
- Window App
- Topic: command
- Commands:
- Lift/value(value need to provide in range 1000 to 10000)
- Tilt/value(value need to provide in range 1000 to 10000)
```

- Click **Publish** to execute the command.

![Silicon Labs - Matter + AWS design](images/control-device-through-cloud.png)
# Matter + AWS Component

- Matter + AWS is a Silicon Labs–specific feature that enables Matter devices to connect directly to
proprietary cloud solutions, such as AWS Cloud. As such, a Matter Wi-Fi device
must support connecting locally on the Matter Fabric via IPv6 and
connecting to the Internet via IPv4.
- Matter devices can be controlled by chip-tool or a controller. The
status of the modified attributes will be published to the cloud.
- Remote users can install a cloud-specific application to receive
notifications about the attribute status.

## Matter + AWS Feature Diagram

The following diagram shows end-to-end flow for Direct Internet Connectivity.

![Silicon Labs - Matter + AWS design](./images/matter-aws-flow.png)

## Prerequisites

### Hardware Requirements

For a list of hardware requirements for the Matter + AWS feature, see the
official
[Silicon Labs Matter hardware requirements](https://siliconlabs.github.io/matter/latest/general/HARDWARE_REQUIREMENTS.html)
documentation.

> Note: This feature is only supported for 917SOC

### Software Requirements

For a list of software requirements for the Matter + AWS feature, see the
official
[Silicon Labs Matter Software requirements](https://siliconlabs.github.io/matter/latest/general/SOFTWARE_REQUIREMENTS.html)
documentation.

## End-to-End Set-up bring up

### Message Queuing Telemetry Transport (MQTT)

MQTT is an OASIS standard messaging protocol for the Internet of Things
(IoT). It is designed as an extremely lightweight publish/subscribe
messaging transport that is ideal for connecting remote devices with a small
code footprint and minimal network bandwidth.
For more details, visit https://mqtt.org/.

### Configuring the MQTT server

To set up and configure AWS for Matter + AWS support, see the following documentation:

- [AWS installation](./aws-configuration-registration.md)

### Remote User Setup (MQTT Explorer) (optional)

Remote users are used to check the state of Matter devices. In this context, MQTT Explorer acts as a remote user. For more information, see [MQTT Explorer Setup and Configuration](./mqtt-explorer-setup.md).

### Building Matter + AWS Application using Simplicity Studio

Follow the instructions in [Build MATTER + AWS](./build-matter-aws.md) to enable the MATTER + AWS feature in your application code.


## End-to-End Test of Matter + AWS Application

User Setup (MQTT Explorer):

- Sharing status of device to cloud
- The following diagram shows the end-to-end flow for sharing status from a Matter device to the cloud.

![Silicon Labs - Matter + AWS design](images/dic-status-sharing.png)

**Note**: For reference, the diagram shows Lighting App commands. Other application commands also can be passed.

- For the end-to-end commands to be executed from chip-tool, refer to [Running the Matter Demo Over Wi-Fi](/matter/{build-docspace-version}/matter-wifi-run-demo).
- The following application-specific attributes or states are shared to the cloud:
- For Lighting App, On/Off Attributes
- For Lock App, lock/unlock Attributes
- For Windows App, lift/tilt Attributes
- For Thermostat App, SystemMode/CurrentTemp/LocalTemperature/OccupiedCoolingSetpoint/OccupiedHeatingSetpoint Attributes
- For On/off Plug App, On/Off Attributes
- The MQTT Explorer UI updates the application status as shown in following image.

![Matter + AWS status update](images/mqtt-explorer-4.png)

- Control of the device through cloud interface
- The following diagram shows the end-to-end flow for control of the Matter device through a cloud interface.

![Silicon Labs - Matter + AWS design](images/dic-control-part.png)

**Note**: For reference, the diagram shows Lighting App commands. Other application commands also can be passed.

- Ensure that the Matter device is running and successfully commissioned. For detailed steps, refer to [Running the Matter Demo Over Wi-Fi](/matter/{build-docspace-version}/matter-wifi-run-demo).
- To control the device, set the topic name and the commands to be executed in the MQTT Explorer for the following applications.

```shell
- Lighting App
- Topic: command
- Commands:
- toggle
- on
- off
- Onoff-plug App
- Topic: command
- Commands:
- toggle
- on
- off
- Lock App
- Topic: command
- Commands:
- lock
- unlock
- Thermostat App
- Topic: command
- Commands:
- SetMode/value(value need to provide 1,2,3,4 ex:SetMode/1)
- Heating/value(value need to provide 2500,2600 ex:HeatingSetPoint/2500)
- Cooling/value(value need to provide 2500,2600 ex:CoolingSetPoint/2500)
- Window App
- Topic: command
- Commands:
- Lift/value(value need to provide in range 1000 to 10000)
- Tilt/value(value need to provide in range 1000 to 10000)
```

- Click **Publish** to execute the command.

![Silicon Labs - Matter + AWS design](images/control-device-through-cloud.png)